chipsenkbeil / chipsenkbeil/distant.nvim

0.3 error when using Telescope "Cancellation failed because no search found"

Open
#115 6 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Lua
Stars
1.4k
Forks
16
PR merge metrics
No merged PRs in 30d

Description

This error is occuring on 0.3, pretty much 100% of the time. Sometimes - rarely - the search results do load, albeit super slowly and without a preview window.
It's possible that my config is incorrect.
I understand that you already refactored the plugin since it's checkbox is ticked - sorry if I'm making an issue too early while it's still WIP.

https://github.com/chipsenkbeil/distant.nvim/assets/11005950/9eddcd2c-ff21-44f6-b032-678a7339e1c9

```lua
Error executing vim.schedule lua callback: ...istant.nvim/lua/telescope/_extensions/distant/finder.lua:127: (other) [Query 2652474811] Cancellation failed because no search found
stack traceback:
[C]: in function 'assert'
...istant.nvim/lua/telescope/_extensions/distant/finder.lua:127: in function 'cb'
...istant.nvim/lua/telescope/_extensions/distant/finder.lua:195: in function 'cb'
...er/start/distant.nvim/lua/distant-core/api/transport.lua:220: in function 'cb'
...er/start/distant.nvim/lua/distant-core/api/transport.lua:478: in function '__handle_response'
...er/start/distant.nvim/lua/distant-core/api/transport.lua:138: in function '__on_stdout_line'
.../pack/packer/start/distant.nvim/lua/distant-core/job.lua:296: in function 'cb'
.../pack/packer/start/distant.nvim/lua/distant-core/job.lua:200: in function ''
vim/_editor.lua: in function
```

#### Distant-server.log

```lua
[2023-07-27 11:13:23.173245 +02:00] DEBUG [distant-net/src/server/connection.rs:511] [Conn 1731928838] New request 4139276815_9868
[2023-07-27 11:13:23.173315 +02:00] DEBUG [distant-local/src/api.rs:364] [Conn 1731928838] Reading metadata for "/var/fpwork/akaluza/project/" {canonicalize: true, resolve_file_type: true}
[2023-07-27 11:13:23.235822 +02:00] DEBUG [distant-net/src/server/connection.rs:511] [Conn 1731928838] New request 4139276815_9520
[2023-07-27 11:13:23.235900 +02:00] DEBUG [distant-local/src/api.rs:619] [Conn 1731928838] Reading system information
[2023-07-27 11:13:23.297480 +02:00] DEBUG [distant-net/src/server/connection.rs:511] [Conn 1731928838] New request 4139276815_9477
[2023-07-27 11:13:23.297560 +02:00] DEBUG [distant-local/src/api.rs:125] [Conn 1731928838] Reading directory "/var/fpwork/akaluza/project" {depth: 1, absolute: false, canonicalize: false, include_root: false}
[2023-07-27 11:13:27.483223 +02:00] DEBUG [distant-net/src/server/connection.rs:511] [Conn 1731928838] New request 4139276815_7896
[2023-07-27 11:13:27.483356 +02:00] DEBUG [distant-local/src/api.rs:364] [Conn 1731928838] Reading metadata for "/var/fpwork/akaluza/project/log_description/" {canonicalize: true, resolve_file_type: true}
[2023-07-27 11:13:27.548091 +02:00] DEBUG [distant-net/src/server/connection.rs:511] [Conn 1731928838] New request 4139276815_6818
[2023-07-27 11:13:27.548151 +02:00] DEBUG [distant-local/src/api.rs:125] [Conn 1731928838] Reading directory "/var/fpwork/akaluza/project/log_description" {depth: 1, absolute: false, canonicalize: false, include_root: false}
```

#### .cache/distant/client.log
```
[2023-07-27 11:13:24.264433 +02:00] INFO [distant-net/src/common/connection.rs:273] [Conn 1509300341] Connect com
pleted successfully!
[2023-07-27 11:13:24.264583 +02:00] INFO [src/cli/common/client.rs:79] Connected to unix socket @ "/home/akaluza/
.cache/nvim/distant.nvim/nvim-2983.sock"
[2023-07-27 11:14:52.146250 +02:00] ERROR [src/cli/commands/client.rs:246] data did not match any variant of unta
gged enum Msg at line 1 column 47
[2023-07-27 11:14:57.101728 +02:00] ERROR [src/cli/commands/client.rs:246] data did not match any variant of unta
gged enum Msg at line 1 column 47
```
#### Config
```lua
// lua/akaluza/packer.lua:
//
use {
'chipsenkbeil/distant.nvim',
branch = 'v0.3',
config = function()
-- local actions = require('distant.nav.actions')
require('distant'):setup {
['network.private'] = true,
keymap = {

},
-- ['*'] = require('akaluza.distant_conf').alan_default()

servers = {
["*"] = {
lsp = {
['project'] = {
cmd = { '/5/tools/llvm/15.0_042/bin/clangd'},
filetypes = {'c', 'cpp'},
root_dir = '/var/fpwork/akaluza/project/',
on_attach = function ()
end,
opts = { log_file = '/var/fpwork/akaluza/distant-server/lsp.log', verbose = 3 }
}
},
cwd = "/var/fpwork/akaluza/project/",
}
}
}
end
}

// after/plugin/telescope.lua:
//
vim.keymap.set('n', 't', function()
require('telescope').extensions.distant.search({
paths = {'/var/fpwork/akaluza/project/'},
pagination = 1,
})
end)
```

**Local machine**: `Ubuntu 22.04.1 LTS on WSL`
**Remote machine**: `Red Hat Enterprise Linux Server 7.5 (Maipo)`
**Distant version:** `0.20 musl`.
**Distant.nvim version**: `0.3` on latest commit `17bcd37`.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.