Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[coc.nvim] TypeError: t.words is not iterable #3778

Closed
kevinmarquesp opened this issue Apr 24, 2022 · 1 comment
Closed

[coc.nvim] TypeError: t.words is not iterable #3778

kevinmarquesp opened this issue Apr 24, 2022 · 1 comment

Comments

@kevinmarquesp
Copy link

Result from CocInfo

versions

vim version: NVIM v0.7.0
node version: v17.9.0
coc.nvim version: 0.0.80-3eedf39d 2022-04-22 20:38:57 +0800
coc.nvim directory: /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim
term: tmux
platform: linux

Log of coc.nvim

2022-04-24T08:51:51.704 WARN (pid:17437) [workspace] - workspace.createOutputChannel is deprecated, please use window.createOutputChannel instead.
at new Logger (/home/kevin/.config/coc/extensions/node_modules/coc-discord/lib/utils/logger.js:10:44)
at Object. (/home/kevin/.config/coc/extensions/node_modules/coc-discord/lib/index.js:16:16)
2022-04-24T08:51:51.843 INFO (pid:17437) [coc-discord-rpc] - === Extension activated ===
2022-04-24T08:51:51.843 INFO (pid:17437) [coc-discord-rpc] - Extension Name: leonardssh.coc-discord-rpc.
2022-04-24T08:51:51.844 INFO (pid:17437) [coc-discord-rpc] - Extension Version: 5.0.5-5994b328.
2022-04-24T08:51:51.865 INFO (pid:17437) [services] - registered service "highlight"
2022-04-24T08:51:52.159 INFO (pid:17437) [plugin] - coc.nvim initialized with node: v17.9.0 after 936ms
2022-04-24T08:51:52.285 ERROR (pid:17437) [coc-discord-rpc] - Error: Could not connect
at Socket.o (/home/kevin/.config/coc/extensions/node_modules/coc-discord-rpc/dist/index.js:2:14782)
at Object.onceWrapper (node:events:642:26)
at Socket.emit (node:events:527:28)
at emitErrorNT (node:internal/streams/destroy:164:8)
at emitErrorCloseNT (node:internal/streams/destroy:129:3)
at processTicksAndRejections (node:internal/process/task_queues:83:21)
2022-04-24T08:51:52.290 ERROR (pid:17437) [extensions] - Error on active extension coc-discord-rpc: Cannot read properties of null (reading 'write') TypeError: Cannot read properties of null (reading 'write')
at e.exports.send (/home/kevin/.config/coc/extensions/node_modules/coc-discord-rpc/dist/index.js:2:16144)
at /home/kevin/.config/coc/extensions/node_modules/coc-discord-rpc/dist/index.js:2:16222
at new Promise ()
at e.exports.close (/home/kevin/.config/coc/extensions/node_modules/coc-discord-rpc/dist/index.js:2:16179)
at e.exports.destroy (/home/kevin/.config/coc/extensions/node_modules/coc-discord-rpc/dist/index.js:2:10989)
at Function.login (/home/kevin/.config/coc/extensions/node_modules/coc-discord-rpc/dist/index.js:2:39568)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Object.t.activate (/home/kevin/.config/coc/extensions/node_modules/coc-discord-rpc/dist/index.js:2:44242)
2022-04-24T08:52:23.651 INFO (pid:17437) [services] - registered service "sumneko-lua"
2022-04-24T08:52:23.655 INFO (pid:17437) [services] - Sumneko Lua Language Server state change: stopped => starting
2022-04-24T08:52:23.682 INFO (pid:17437) [language-client-index] - Language server "sumneko-lua" started with 18131
2022-04-24T08:52:24.014 INFO (pid:17437) [services] - Sumneko Lua Language Server state change: starting => running
2022-04-24T08:52:24.028 INFO (pid:17437) [services] - service sumneko-lua started
2022-04-24T08:52:26.677 INFO (pid:17437) [attach] - Request action: diagnosticList []
2022-04-24T08:52:51.025 INFO (pid:17437) [attach] - Request action: diagnosticList []
2022-04-24T08:52:51.035 INFO (pid:17437) [attach] - Request action: diagnosticList []
2022-04-24T08:52:51.789 INFO (pid:17437) [attach] - Request action: diagnosticList []
2022-04-24T08:52:51.790 INFO (pid:17437) [attach] - Request action: diagnosticList []
2022-04-24T08:52:56.084 ERROR (pid:17437) [node-client] - Cannot read properties of undefined (reading 'charCodeAt') TypeError: Cannot read properties of undefined (reading 'charCodeAt')
at mg.isKeywordChar (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:177:1524)
at jb.getWordRangeAtPosition (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:183:4626)
at i.provideCompletionItems (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:918)
at Kw.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:263:9855)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31748
at new Promise ()
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31710)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31179
at Array.map ()
at hx.completeSources (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31167)
2022-04-24T08:52:56.084 ERROR (pid:17437) [completion-complete] - Complete error: coc-dash-complete TypeError: Cannot read properties of undefined (reading 'charCodeAt')
at mg.isKeywordChar (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:177:1524)
at jb.getWordRangeAtPosition (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:183:4626)
at i.provideCompletionItems (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:918)
at Kw.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:263:9855)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31748
at new Promise ()
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31710)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31179
at Array.map ()
at hx.completeSources (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31167)
2022-04-24T08:52:56.189 ERROR (pid:17437) [node-client] - TypeError: t.words is not iterable Error
at nA.echoError (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:35:1869)
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:32341)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Promise.all (index 3)
at async hx.completeSources (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31131)
at async hx.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:30602)
at async wee.startCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:42281)
at async wee.triggerCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:46056)
at async wee.onTextChangedI (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:44786)
2022-04-24T08:52:56.190 ERROR (pid:17437) [completion-complete] - Complete error: coc-dash-complete TypeError: t.words is not iterable
at /home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1264
at Array.forEach ()
at i.gatherWords (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1218)
at i.provideCompletionItems (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1030)
at Kw.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:263:9855)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31748
at new Promise ()
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31710)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31179
at Array.map ()
2022-04-24T08:52:56.308 ERROR (pid:17437) [node-client] - TypeError: t.words is not iterable Error
at nA.echoError (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:35:1869)
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:32341)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Promise.all (index 3)
at async hx.completeSources (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31131)
at async hx.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:30602)
at async wee.startCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:42281)
at async wee.triggerCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:46056)
at async wee.onTextChangedI (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:44786)
2022-04-24T08:52:56.308 ERROR (pid:17437) [completion-complete] - Complete error: coc-dash-complete TypeError: t.words is not iterable
at /home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1264
at Array.forEach ()
at i.gatherWords (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1218)
at i.provideCompletionItems (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1030)
at Kw.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:263:9855)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31748
at new Promise ()
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31710)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31179
at Array.map ()
2022-04-24T08:52:56.506 ERROR (pid:17437) [node-client] - TypeError: t.words is not iterable Error
at nA.echoError (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:35:1869)
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:32341)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Promise.all (index 3)
at async hx.completeSources (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31131)
at async hx.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:30602)
at async wee.startCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:42281)
at async wee.triggerCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:46056)
at async wee.onTextChangedI (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:44786)
2022-04-24T08:52:56.507 ERROR (pid:17437) [completion-complete] - Complete error: coc-dash-complete TypeError: t.words is not iterable
at /home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1264
at Array.forEach ()
at i.gatherWords (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1218)
at i.provideCompletionItems (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1030)
at Kw.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:263:9855)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31748
at new Promise ()
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31710)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31179
at Array.map ()
2022-04-24T08:52:57.560 ERROR (pid:17437) [node-client] - TypeError: t.words is not iterable Error
at nA.echoError (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:35:1869)
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:32341)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Promise.all (index 3)
at async hx.completeSources (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31131)
at async hx.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:30602)
at async wee.startCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:42281)
at async wee.triggerCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:46056)
at async Timeout. (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:44906)
2022-04-24T08:52:57.560 ERROR (pid:17437) [completion-complete] - Complete error: coc-dash-complete TypeError: t.words is not iterable
at /home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1264
at Array.forEach ()
at i.gatherWords (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1218)
at i.provideCompletionItems (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1030)
at Kw.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:263:9855)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31748
at new Promise ()
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31710)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31179
at Array.map ()
2022-04-24T08:52:57.643 ERROR (pid:17437) [node-client] - TypeError: t.words is not iterable Error
at nA.echoError (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:35:1869)
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:32341)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Promise.all (index 3)
at async hx.completeSources (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31131)
at async hx.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:30602)
at async wee.startCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:42281)
at async wee.triggerCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:46056)
at async wee.onTextChangedI (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:44786)
2022-04-24T08:52:57.644 ERROR (pid:17437) [completion-complete] - Complete error: coc-dash-complete TypeError: t.words is not iterable
at /home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1264
at Array.forEach ()
at i.gatherWords (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1218)
at i.provideCompletionItems (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1030)
at Kw.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:263:9855)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31748
at new Promise ()
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31710)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31179
at Array.map ()
2022-04-24T08:52:58.007 ERROR (pid:17437) [node-client] - TypeError: t.words is not iterable Error
at nA.echoError (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:35:1869)
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:32341)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async Promise.all (index 3)
at async hx.completeSources (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31131)
at async hx.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:30602)
at async wee.startCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:42281)
at async wee.triggerCompletion (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:46056)
at async Timeout. (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:44906)
2022-04-24T08:52:58.007 ERROR (pid:17437) [completion-complete] - Complete error: coc-dash-complete TypeError: t.words is not iterable
at /home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1264
at Array.forEach ()
at i.gatherWords (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1218)
at i.provideCompletionItems (/home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1030)
at Kw.doComplete (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:263:9855)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31748
at new Promise ()
at hx.completeSource (/home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31710)
at /home/kevin/.local/share/nvim/site/pack/packer/start/coc.nvim/build/index.js:267:31179
at Array.map ()
2022-04-24T08:58:27.813 INFO (pid:17437) [attach] - Request action: diagnosticList []
2022-04-24T08:58:35.130 INFO (pid:17437) [attach] - receive notification: showInfo []

Describe the bug

Thats really anoying, when Im in insert mode typing, sometimes the vim complain about this [coc.vim] TypeError: t.words is not iterable error. I dont know if it is caused by a plugin or is just the coc...

Reproduce the bug

I dont know how it happens and dont know if my config will help, but here is my options that I use in Neovim...

  • Here is my options.lua file:
 options {
    backup = false,
    clipboard = 'unnamedplus',
    ignorecase = true,

    encoding = 'UTF-8',
    termguicolors = true,
    timeoutlen = 500,

    hidden = true,
    confirm = true,
    cursorline = true,
    inccommand = 'split',
    mouse = 'a',
    showmode = false,

    number = true,
    numberwidth = 6,
    splitbelow = true,
    splitright = true,

    expandtab = true,
    smartindent = false,
    shiftwidth = 4,
    tabstop = 4,
    breakindent = true,
    formatoptions = '1',
    linebreak = true,
    wrap = false
}

vim.cmd [[
    set nocompatible path+=**
    set fcs=eob:\ 
]]

Screenshots (optional)

image

@chemzqm
Copy link
Member

chemzqm commented Apr 24, 2022

Complete error: coc-dash-complete TypeError: t.words is not iterable
at /home/kevin/.config/coc/extensions/node_modules/coc-dash-complete/lib/index.js:1:1264

Seems bug with your coc-dash-complete

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants