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

Enterprise - Cody Not Working #258

Open
RobertBattaglia opened this issue Aug 22, 2024 · 4 comments
Open

Enterprise - Cody Not Working #258

RobertBattaglia opened this issue Aug 22, 2024 · 4 comments

Comments

@RobertBattaglia
Copy link
Contributor

RobertBattaglia commented Aug 22, 2024

Hello,
My org recently announced that Enterprise Model Selection is now available on our production instance.

Around the same time, Cody stopped working completely for me in Neovim. The version of this plugin did not change in the meantime, and I created a new Personal Access Token just in case.

`sg: require("sg.health").check()

sg.nvim report ~

  • Machine: arm64, sysname: Darwin
  • OK Valid nvim version: 0.10.1
  • WARNING Unable to find valid cargo executable. Trying to build sg.nvim locally will fail. Instead use :SourcegraphDownloadBinaries
  • OK Found sg-nvim-agent: "/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/sg-nvim-agent"
  • OK Found node (config.node_executable) is executable.
    Version: '18.20.4'
  • OK Found cody-agent: /Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/cody-agent.js
  • OK Authentication setup correctly
  • OK endpoint set to: https://.sourcegraph.com
  • OK Found correct binary versions: "1.1.0" = "1.1.0"
  • OK Sourcegraph Connection info: {
    access_token_set = true,
    endpoint = "https://.sourcegraph.com",
    sg_nvim_version = "1.1.0",
    sourcegraph_version = {
    build = "5.6.185",
    product = "5.6.185"
    }
    }
  • To manage your Cody Account, navigate to: https://sourcegraph.com/cody/manage
  • OK Cody Account Information: {
    cody_pro_enabled = false,
    username = "rbattaglia"
    }
  • OK sg.nvim is ready to run`

Cody does appear to be working in other IDE Cody plugins, tested with IntelliJ. I can see all the models available:
Screenshot 2024-08-22 at 5 11 28 PM.

In Neovim, I cannot see all these models:
Screenshot 2024-08-22 at 5 17 04 PM

I also tried to set the model in the config.chat.defaultModel to match something I saw in the dropdown in IntelliJ.

Looks like error is somewhere in the Cody Agent from lsp.log
[ERROR][2024-08-22 17:17:38] .../vim/lsp/rpc.lua:770 "rpc" "/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/sg-nvim-agent" "stderr" "[sg-nvim-agent] failed to read message data did not match any variant of untagged enum Message\n"
[ERROR][2024-08-22 17:17:39] .../vim/lsp/rpc.lua:770 "rpc" "/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/sg-nvim-agent" "stderr" 'Recieved a message: Request { id: 2, data: SourcegraphRemoteURL { path: "/Users/robbattaglia/dotfiles/nvim/.config/nvim/" } }\nDATA : SourcegraphRemoteURL { path: "/Users/robbattaglia/dotfiles/nvim/.config/nvim/" }\n'
[ERROR][2024-08-22 17:17:43] .../vim/lsp/rpc.lua:770 "rpc" "node" "stderr" '{"stack":"Error: Timeout\n at Timeout._onTimeout (/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/cody-agent.js:277769:20)\n at listOnTimeout (node:internal/timers:569:17)\n at process.processTimers (node:internal/timers:512:7)","message":"Timeout","name":"Error"}\n'
[WARN][2024-08-22 17:17:45] ...lsp/handlers.lua:135 "The language server copilot triggers a registerCapability handler for workspace/didChangeWorkspaceFolders despite dynamicRegistration set to false. Report upstream, this warning is harmless"
[ERROR][2024-08-22 17:18:05] .../vim/lsp/rpc.lua:770 "rpc" "node" "stderr" '{"stack":"Error: Timeout\n at Timeout._onTimeout (/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/cody-agent.js:277769:20)\n at listOnTimeout (node:internal/timers:569:17)\n at process.processTimers (node:internal/timers:512:7)","message":"Timeout","name":"Error"}\n'
[ERROR][2024-08-22 17:18:15] .../vim/lsp/rpc.lua:770 "rpc" "node" "stderr" '{"stack":"Error: Timeout\n at Timeout._onTimeout (/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/cody-agent.js:277769:20)\n at listOnTimeout (node:internal/timers:569:17)\n at process.processTimers (node:internal/timers:512:7)","message":"Timeout","name":"Error"}\n'
[ERROR][2024-08-22 17:18:19] .../vim/lsp/rpc.lua:770 "rpc" "node" "stderr" '{"stack":"Error: Timeout\n at Timeout._onTimeout (/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/cody-agent.js:277769:20)\n at listOnTimeout (node:internal/timers:569:17)\n at process.processTimers (node:internal/timers:512:7)","message":"Timeout","name":"Error"}\n'
[ERROR][2024-08-22 17:19:05] .../vim/lsp/rpc.lua:770 "rpc" "node" "stderr" '{"stack":"Error: Timeout\n at Timeout._onTimeout (/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/cody-agent.js:277769:20)\n at listOnTimeout (node:internal/timers:569:17)\n at process.processTimers (node:internal/timers:512:7)","message":"Timeout","name":"Error"}\n'
[ERROR][2024-08-22 17:19:19] .../vim/lsp/rpc.lua:770 "rpc" "node" "stderr" '{"stack":"Error: Timeout\n at Timeout._onTimeout (/Users/robbattaglia/.local/share/nvim/lazy/sg.nvim/dist/cody-agent.js:277769:20)\n at listOnTimeout (node:internal/timers:569:17)\n at process.processTimers (node:internal/timers:512:7)","message":"Timeout","name":"Error"}\n'

@julienTraversier
Copy link

Same here it used to work, but not anymore.

@guillemaru
Copy link

Same here, it stopped working in the last days, with an enterprise account...

@guillemaru
Copy link

I have written a new plugin that is a convenient wrapper around the Cody CLI for the functionality that I needed, in case it can be useful to anyone:
https://github.com/guillemaru/codyassist

@travisbrady
Copy link

I'm having the same issue. Is there any workaround for this?

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

4 participants