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

amazonq: Q panel is empty, "error when fetching configs" (raspberry pi + vscode.dev) #5753

Open
pugpapa opened this issue Oct 9, 2024 · 16 comments
Labels
amazonq bug We can reproduce the issue and confirmed it is a bug. guidance General information and guidance, answers to FAQs, or recommended best practices/resources. platform:web webview

Comments

@pugpapa
Copy link

pugpapa commented Oct 9, 2024

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

  • OS: PiOS
  • Visual Studio Code version: 1.93.1
  • AWS Toolkit version:
  • Amazon Q version: 1.28

Question

I'm on a Raspberry Pi5 and wanting to use Amazon Q on vscode.dev to develop over the remote tunnel. Is this possible? I am able use it when I'm on the Raspberry Pi itself, but not remotely.

@pugpapa pugpapa added the guidance General information and guidance, answers to FAQs, or recommended best practices/resources. label Oct 9, 2024
@justinmk3
Copy link
Contributor

Not yet, but subscribe to #2205 for future updates.

@justinmk3
Copy link
Contributor

justinmk3 commented Oct 24, 2024

#5847 may fix the "remote tunnel" case.

@hayemaxi
Copy link
Contributor

This may have been fixed in Amazon Q 1.31.0, can you verify?

@pugpapa
Copy link
Author

pugpapa commented Oct 30, 2024

It is not. I am on 1.32 and when I click on the red box to sign in with my Builder ID, nothing happens. Is there an alternate way to authenticate?

@justinmk3
Copy link
Contributor

justinmk3 commented Oct 30, 2024

Can you provide the Amazon Q logs?

  1. In the vscode command palette, run Amazon Q: View Logs. This reveals the Output panel with Amazon Q Logs selected.
  2. Click the gear icon and choose Debug, then click it again and choose Set As Default.
  3. Perform the steps to reproduce the issue.
  4. Remove any private info from the logs.

Also need details on what is meant by "over the remote tunnel" specifically. Because there are many ways in vscode to use it remotely. Please say the exact steps you use to connect to vscode remote tunnel.

A screenshot (with private info removed) may help.

@pugpapa
Copy link
Author

pugpapa commented Nov 2, 2024

2024-11-02 15:59:02.301 [debug] telemetry: collapsing 1 "aws.amazonq.listCommands" metrics. key={}
2024-11-02 15:59:02.301 [debug] command: running "aws.amazonq.listCommands" with arguments: []
2024-11-02 15:59:02.301 [debug] telemetry: ui_click
2024-11-02 15:59:02.301 [debug] telemetry: collapsing 1 "aws.amazonq.refreshAnnotation" metrics. key={}
2024-11-02 15:59:02.301 [debug] command: running "aws.amazonq.refreshAnnotation" with arguments: [ true ]
2024-11-02 15:59:07.057 [debug] telemetry: collapsing 1 "aws.amazonq.focusChat" metrics. key={ '1': 'source' }
2024-11-02 15:59:07.057 [debug] command: running "aws.amazonq.focusChat" with arguments: [ 'placeholder**', 'codewhispererQuickPick' ]
2024-11-02 15:59:07.128 [debug] telemetry: auth_signInPageOpened
2024-11-02 15:59:07.128 [debug] telemetry: amazonq_openChat

But nothing happens

In case a process tree is helpful:


   1179    1204    1204    1204 ?             -1 SLsl  1000   1:12  \_ /usr/share/code/bin/code-tunnel --verbose --cli-data-dir /home/pugpapa/.vscode/cli tunnel service internal
   1204  327256    1204    1204 ?             -1 S     1000   0:00  |   \_ sh /home/pugpapa/.vscode/cli/servers/Stable-65edc4939843c90c34d61f4ce11704f09d3e5cb6/server/bin/code-s
 327256  327260    1204    1204 ?             -1 Sl    1000   0:10  |       \_ /home/pugpapa/.vscode/cli/servers/Stable-65edc4939843c90c34d61f4ce11704f09d3e5cb6/server/node /hom
 327260  327302    1204    1204 ?             -1 Sl    1000   0:00  |           \_ /home/pugpapa/.vscode/cli/servers/Stable-65edc4939843c90c34d61f4ce11704f09d3e5cb6/server/node 
 327302  327421  327421  327421 pts/1     327421 Ss+   1000   0:00  |           |   \_ /bin/bash --init-file /home/pugpapa/.vscode/cli/servers/Stable-65edc4939843c90c34d61f4ce11
 327260  327350    1204    1204 ?             -1 Sl    1000   0:00  |           \_ /home/pugpapa/.vscode/cli/servers/Stable-65edc4939843c90c34d61f4ce11704f09d3e5cb6/server/node 
 327260  327518    1204    1204 ?             -1 Sl    1000   0:26  |           \_ /home/pugpapa/.vscode/cli/servers/Stable-65edc4939843c90c34d61f4ce11704f09d3e5cb6/server/node 
 327518  327683    1204    1204 ?             -1 Sl    1000   0:01  |           |   \_ Amazon Q Helper (Workspace Context)
 327518  328580    1204    1204 ?             -1 Sl    1000   0:00  |           |   \_ /home/pugpapa/.vscode/cli/servers/Stable-65edc4939843c90c34d61f4ce11704f09d3e5cb6/server/n
 327260  327549    1204    1204 ?             -1 Sl    1000   0:00  |           \_ /home/pugpapa/.vscode/cli/servers/Stable-65edc4939843c90c34d61f4ce11704f09d3e5cb6/server/node 

I've started up the server on my Pi, and using vscode.dev (connected to my GitHub) to tunnel in.

Not sure what happens on their side, but these are the docs: https://code.visualstudio.com/docs/remote/tunnels

@justinmk3
Copy link
Contributor

justinmk3 commented Nov 4, 2024

when I click on the red box to sign in with my Builder ID, nothing happens

Try clicking it again. There is a known usability issue where if an item in the login menu is expired, it may require multiple clicks.

If that doesn't work, try clicking the Q logo in the vscode sidebar, it should show a login form like this:

image

If you don't see the Q logo in the sidebar, right-click on the sidebar to enable it:

image

@pugpapa
Copy link
Author

pugpapa commented Nov 7, 2024

Nothing shows up in the Q box
Screenshot 2024-11-06 at 21 05 06

@justinmk3 justinmk3 changed the title Raspberry Pi + vscode.dev amazonq: Q panel is empty (raspberry pi + vscode.dev) Nov 7, 2024
@justinmk3 justinmk3 added amazonq webview bug We can reproduce the issue and confirmed it is a bug. labels Nov 7, 2024
@justinmk3
Copy link
Contributor

Possibly vscode's own logs might give a hint, if you can provide those. If vscode is not showing the extension webview, that's very unusual. Does that happen with any other extensions that use webviews, on that same system?

@pugpapa
Copy link
Author

pugpapa commented Nov 9, 2024

I took a screen recording, take a look here: https://1drv.ms/v/s!Amsb28k2KHrZg7NTCWnPT_oaa4JjYQ?e=DmCFHE

@justinmk3
Copy link
Contributor

justinmk3 commented Nov 11, 2024

Just for troubleshooting, can you try also installing AWS Toolkit (on the same system where Amazon Q is showing a blank view)? I'm wondering if Amazon Q has a bug related to its (optional) dependency on AWS Toolkit.

@pugpapa
Copy link
Author

pugpapa commented Nov 11, 2024

Q and toolkit are installed now. No signin screen in either. Here are the logs:

2024-11-11 09:25:36.438 [info] Log level: info
2024-11-11 09:25:36.438 [info] Telemetry product: Amazon Q For VS Code
2024-11-11 09:25:36.597 [info] Telemetry clientId: 051ddced-421c-4510-8b25-8cb062f906d1
2024-11-11 09:25:36.598 [info] Telemetry sessionId: 866ce2bc-2c29-490a-8091-43782997ed3d
2024-11-11 09:25:36.598 [info] codewhisperer: active connection changed
2024-11-11 09:25:36.598 [info] codewhisperer: connection states
    connection isValid=false,
    connection isValidCodewhispererCoreConnection=false,
    connection isExpired=false,
    secondaryAuth isExpired=false,
    connection isUndefined=true
2024-11-11 09:25:36.807 [error] CodeWhisperer: Error when fetching feature configs Error: No connection found
2024-11-11 09:25:36.807 [error] CodeWhisperer: Error when fetching feature configs Error: No connection found
2024-11-11 09:25:38.266 [info] initialized 'submitFeedback' command with default feedback id: Amazon Q
2024-11-11 09:25:43.406 [info] LspController: LSP already installed
2024-11-11 09:25:44.334 [info] LspController: LSP activated
2024-11-11 09:25:44.334 [info] LspController: Starting to build index of project
2024-11-11 09:26:07.070 [info] Trying to register toolkit callback. Toolkit is installed, 
                        toolkit activated = false
2024-11-11 09:26:07.070 [info] toolkitApi: Registering callbacks of toolkit api
2024-11-11 09:27:13.984 [debug] telemetry: auth_signInPageClosed
2024-11-11 09:27:13.984 [debug] telemetry: auth_addConnection
2024-11-11 09:27:13.984 [debug] telemetry: amazonq_closeChat
2024-11-11 09:27:20.723 [debug] telemetry: auth_signInPageOpened
2024-11-11 09:27:20.723 [debug] telemetry: amazonq_openChat
2024-11-11 09:26:04.202 [info] Log level: info
2024-11-11 09:26:04.202 [info] endpoints: retrieving AWS endpoints data
2024-11-11 09:26:04.202 [info] Telemetry product: AWS Toolkit For VS Code
2024-11-11 09:26:04.282 [info] Telemetry clientId: 051ddced-421c-4510-8b25-8cb062f906d1
2024-11-11 09:26:04.282 [info] Telemetry sessionId: 866ce2bc-2c29-490a-8091-43782997ed3d
2024-11-11 09:26:05.533 [info] OS: Linux arm64 6.6.51+rpt-rpi-2712
2024-11-11 09:26:05.533 [info] Visual Studio Code extension host:  1.95.2
2024-11-11 09:26:05.533 [info] AWS Toolkit:  3.32.0
2024-11-11 09:26:05.533 [info] node: 20.18.0
2024-11-11 09:26:05.564 [info] initialized 'submitFeedback' command with default feedback id: AWS Toolkit
2024-11-11 09:26:06.225 [warning] Ec2MetadataClient failed to fetch token. If this is an EC2 environment, then Toolkit will fall back to IMDSv1: TimeoutError: Socket timed out without establishing a connection ()
2024-11-11 09:26:42.987 [debug] telemetry: auth_signInPageClosed
2024-11-11 09:26:42.987 [debug] telemetry: auth_addConnection
2024-11-11 09:26:47.441 [debug] telemetry: auth_signInPageOpened
2024-11-11 09:26:52.097 [debug] telemetry: auth_signInPageClosed
2024-11-11 09:26:52.097 [debug] telemetry: auth_addConnection
2024-11-11 09:26:55.649 [debug] telemetry: auth_signInPageOpened
2024-11-11 09:27:00.990 [debug] telemetry: auth_signInPageClosed
2024-11-11 09:27:00.990 [debug] telemetry: auth_addConnection
2024-11-11 09:27:19.201 [debug] telemetry: auth_signInPageOpened
2024-11-11 09:27:20.723 [debug] telemetry: auth_signInPageClosed
2024-11-11 09:27:20.723 [debug] telemetry: auth_addConnection
2024-11-11 09:28:39.447 [debug] telemetry: auth_signInPageOpened

@justinmk3 justinmk3 changed the title amazonq: Q panel is empty (raspberry pi + vscode.dev) amazonq: Q panel is empty, "error when fetching configs" (raspberry pi + vscode.dev) Nov 11, 2024
@suminhong
Copy link

suminhong commented Nov 12, 2024

I'm going through the same situation.

2024-11-12 18:52:37.152 [info] Log level: info
2024-11-12 18:52:37.152 [info] Telemetry product: Amazon Q For VS Code
2024-11-12 18:52:37.164 [info] Telemetry clientId: e4bbf1a9-0087-42a8-a016-9b734c7579b4
2024-11-12 18:52:37.164 [info] Telemetry sessionId: 31880669-1c86-495e-8962-4fb6196fad02
2024-11-12 18:52:37.164 [info] codewhisperer: active connection changed
2024-11-12 18:52:37.164 [info] codewhisperer: connection states
    connection isValid=false,
    connection isValidCodewhispererCoreConnection=false,
    connection isExpired=false,
    secondaryAuth isExpired=false,
    connection isUndefined=true
2024-11-12 18:52:37.169 [info] Trying to register toolkit callback. Toolkit is installed, 
                        toolkit activated = true
2024-11-12 18:52:37.169 [info] toolkitApi: Registering callbacks of toolkit api
2024-11-12 18:52:37.170 [error] CodeWhisperer: Error when fetching feature configs Error: No connection found
2024-11-12 18:52:37.170 [error] CodeWhisperer: Error when fetching feature configs Error: No connection found
2024-11-12 18:52:37.193 [info] initialized 'submitFeedback' command with default feedback id: Amazon Q
2024-11-12 18:52:37.907 [warning] endpoints: failed to load from remote source, region data may appear outdated: Error: Failed to get resource
2024-11-12 18:52:59.633 [debug] telemetry: collapsing 1 "aws.amazonq.listCommands" metrics. key={}
2024-11-12 18:52:59.633 [debug] command: running "aws.amazonq.listCommands" with arguments: []
2024-11-12 18:52:59.633 [debug] telemetry: ui_click
2024-11-12 18:52:59.633 [debug] telemetry: collapsing 1 "aws.amazonq.refreshAnnotation" metrics. key={}
2024-11-12 18:52:59.633 [debug] command: running "aws.amazonq.refreshAnnotation" with arguments: [ true ]
2024-11-12 18:53:02.526 [debug] telemetry: collapsing 1 "aws.amazonq.focusChat" metrics. key={ '1': 'source' }
2024-11-12 18:53:02.526 [debug] command: running "aws.amazonq.focusChat" with arguments: [ 'placeholder**', 'codewhispererQuickPick' ]
2024-11-12 18:53:07.977 [info] LspController: LSP activated
2024-11-12 18:53:07.977 [info] LspController: Starting to build index of project
2024-11-12 18:53:09.684 [info] LspController: Found 5301 files in current project ...
2024-11-12 18:53:10.939 [debug] LspController: Finish building index of project
2024-11-12 18:53:10.977 [debug] telemetry: amazonq_indexWorkspace
2024-11-12 18:53:15.589 [debug] telemetry: auth_signInPageClosed
2024-11-12 18:53:15.590 [debug] telemetry: auth_addConnection
2024-11-12 18:53:15.590 [debug] telemetry: amazonq_closeChat
2024-11-12 18:53:16.392 [debug] telemetry: auth_signInPageOpened
2024-11-12 18:53:16.392 [debug] telemetry: amazonq_openChat
2024-11-12 18:53:16.855 [debug] telemetry: auth_signInPageClosed
2024-11-12 18:53:16.855 [debug] telemetry: auth_addConnection
2024-11-12 18:53:16.855 [debug] telemetry: amazonq_closeChat
2024-11-12 18:53:17.640 [debug] telemetry: auth_signInPageOpened
2024-11-12 18:53:17.640 [debug] telemetry: amazonq_openChat
2024-11-12 18:56:19.912 [debug] telemetry: collapsing 2 "aws.amazonq.listCommands" metrics. key={}
2024-11-12 18:56:19.912 [debug] command: running "aws.amazonq.listCommands" with arguments: []
2024-11-12 18:56:19.912 [debug] telemetry: ui_click
2024-11-12 18:56:19.912 [debug] telemetry: collapsing 2 "aws.amazonq.refreshAnnotation" metrics. key={}
2024-11-12 18:56:19.912 [debug] command: running "aws.amazonq.refreshAnnotation" with arguments: [ true ]
2024-11-12 18:56:21.041 [debug] telemetry: collapsing 2 "aws.amazonq.focusChat" metrics. key={ '1': 'source' }
2024-11-12 18:56:21.041 [debug] command: running "aws.amazonq.focusChat" with arguments: [ 'placeholder**', 'codewhispererQuickPick' ]

I also tried installing the AWS Toolkit, but no screen appears. The aws toolkit log is as follows.

2024-11-12 18:46:34.615 [info] Log level: info
2024-11-12 18:46:34.630 [info] endpoints: retrieving AWS endpoints data
2024-11-12 18:46:34.630 [info] Telemetry product: AWS Toolkit For VS Code
2024-11-12 18:46:34.633 [info] Telemetry clientId: e4bbf1a9-0087-42a8-a016-9b734c7579b4
2024-11-12 18:46:34.633 [info] Telemetry sessionId: 31880669-1c86-495e-8962-4fb6196fad02
2024-11-12 18:46:34.667 [info] OS: Darwin arm64 23.6.0
2024-11-12 18:46:34.667 [info] Visual Studio Code extension host:  1.95.2
2024-11-12 18:46:34.667 [info] AWS Toolkit:  3.32.0
2024-11-12 18:46:34.667 [info] node: 20.18.0
2024-11-12 18:46:34.667 [info] electron: 32.2.1
2024-11-12 18:46:34.668 [info] initialized 'submitFeedback' command with default feedback id: AWS Toolkit
2024-11-12 18:46:34.736 [warning] Ec2MetadataClient failed to fetch token. If this is an EC2 environment, then Toolkit will fall back to IMDSv1: Error:
2024-11-12 18:46:34.812 [warning] command failed (not registered?): "aws.amazonq.refreshConnectionCallback"
2024-11-12 18:46:35.375 [warning] endpoints: failed to load from remote source, region data may appear outdated: Error: Failed to get resource
2024-11-12 18:47:10.223 [debug] telemetry: collapsing 1 "aws.toolkit.login" metrics. key={}
2024-11-12 18:47:10.224 [debug] command: running "aws.toolkit.login" with arguments: []
2024-11-12 18:47:10.224 [debug] auth: "instance" provider unavailable
2024-11-12 18:47:10.224 [debug] auth: "instance" provider unavailable
2024-11-12 18:47:10.224 [debug] auth: "variables" provider unavailable
2024-11-12 18:47:10.233 [debug] telemetry: aws_loadCredentials
2024-11-12 18:47:10.233 [debug] telemetry: collapsing 1 "aws.toolkit.auth.manageConnections" metrics. key={ '1': 'source' }
2024-11-12 18:47:10.233 [debug] command: running "aws.toolkit.auth.manageConnections" with arguments: [ 'placeholder**', 'vscodeComponent' ]
2024-11-12 18:47:41.979 [debug] telemetry: auth_signInPageClosed
2024-11-12 18:47:41.979 [debug] telemetry: auth_addConnection
2024-11-12 18:47:44.997 [debug] telemetry: auth_signInPageOpened
2024-11-12 18:47:45.503 [debug] telemetry: auth_signInPageClosed
2024-11-12 18:47:45.504 [debug] telemetry: auth_addConnection
2024-11-12 18:47:46.562 [debug] telemetry: auth_signInPageOpened
2024-11-12 18:47:55.052 [debug] telemetry: collapsing 2 "aws.toolkit.login" metrics. key={}
2024-11-12 18:47:55.052 [debug] command: running "aws.toolkit.login" with arguments: []

I deleted all other plugins.
What's causing the problem? When can it be resolved?

thx.

@justinmk3
Copy link
Contributor

justinmk3 commented Nov 12, 2024

2024-11-12 18:52:37.907 [warning] endpoints: failed to load from remote source, region data may appear outdated: Error: Failed to get resource

@suminhong This suggests that http requests are failing. Can you confirm that vscode extensions can successfully make network requests? Are you behind a proxy? Please open a new issue (unless you are also using raspberry pi + vscode.dev).

@suminhong
Copy link

@justinmk3
Oh right. Some outbound services may be blocked due to my company's internal security policy. So can you tell me which domain this should be able to reach? I have to ask security team to open it.

@justinmk3
Copy link
Contributor

which domain this should be able to reach?

At least these, possibly more:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
amazonq bug We can reproduce the issue and confirmed it is a bug. guidance General information and guidance, answers to FAQs, or recommended best practices/resources. platform:web webview
Projects
None yet
Development

No branches or pull requests

4 participants