aws / aws-toolkit-vscode

Amazon Q, CodeCatalyst, Local Lambda debug, SAM/CFN syntax, ECS Terminal, AWS resources
https://marketplace.visualstudio.com/items?itemName=AmazonWebServices.amazon-q-vscode
Apache License 2.0
1.5k stars 427 forks source link

Failed to load library libonnxruntime_providers_cuda.so with error: libonnxruntime_providers_cuda.so: cannot open shared object file: No such file or directory #5868

Open willmakley opened 4 hours ago

willmakley commented 4 hours ago

Problem

On opening a Ruby on Rails project in VSCode, Amazon Q Language Server shows the following error:

Request initialize failed with message: /onnxruntime_src/onnxruntime/core/session/provider_bridge_ort.cc:1637 onnxruntime::Provider& onnxruntime::ProviderLibrary::Get() [ONNXRuntimeError] : 1 : FAIL : Failed to load library libonnxruntime_providers_cuda.so with error: libonnxruntime_providers_cuda.so: cannot open shared object file: No such file or directory

Steps to reproduce the issue

Open a project in VSCode

Expected behavior

No error.

System details (run AWS: About and/or Amazon Q: About)

leigaol commented 3 hours ago

Hi @willmakley , in your Amazon Q VS Code settings, do you have the Amazon Q: Workspace Index Use GPU enabled? If so, is it possible for you to turn it off and then restart or reload VS Code? Thank you!

willmakley commented 2 hours ago

Yes, it was on (by default) and turning it off does seem to have resolved the issue.

leigaol commented 27 minutes ago

On by default is not expected. In our configuration, we make it off by default. https://github.com/aws/aws-toolkit-vscode/blob/master/packages/amazonq/package.json#L157

You are seeing this error because CUDA driver was not ready in the Ubuntu environment. If there is a valid CUDA installed, the error should go away.