- Newest
- Most votes
- Most comments
The answer is to use an older version of Amazon Q. See the solution here: https://github.com/aws/aws-toolkit-vscode/issues/8032
answered 10 months ago
Based on your description, you're experiencing an issue with Amazon Q not being able to properly access files in your multi-root VS Code workspace. This appears to be related to how Amazon Q indexes and recognizes your workspace structure.
Here are some steps you can try to resolve this issue:
- Check Module Configuration in VS Code:
- Ensure that both your frontend and backend components are properly configured as separate modules in the workspace.
- Verify that the directories are correctly marked as source roots.
- Invalidate Caches and Restart:
- Sometimes caching issues can lead to incomplete indexing.
- In VS Code, try reloading the window (Command Palette > Developer: Reload Window).
- You might also need to clear any extension caches.
- Reconfigure the Workspace Index:
- Check if there are any settings for Amazon Q's workspace indexing feature.
- Try disabling and re-enabling the workspace indexing feature.
- Look for any folder exclusions or include/exclude patterns that might be affecting file access.
- Check Workspace Logs:
- Look for any warnings or errors related to workspace indexing in the VS Code logs.
- This might provide clues about why Amazon Q can't resolve the file paths.
- Ensure Proper Directory Structure Recognition:
- Right-click on both the frontend and backend folders in VS Code's Explorer.
- Make sure they are properly recognized as source directories.
- Ensure no folders are mistakenly marked as excluded.
If these steps don't resolve the issue, it might be a limitation with how Amazon Q handles multi-root workspaces. In that case, you might need to contact AWS Support for further assistance, as this appears to be a specific issue with Amazon Q's workspace context handling in multi-root environments.
Sources
Amazon Q Developer workspace context not working in monorepo | AWS re:Post
answered 10 months ago
Relevant content
asked 2 years ago
asked 7 years ago
- AWS OFFICIALUpdated 4 months ago
- AWS OFFICIALUpdated 4 months ago

I've tried all the steps mentioned, still the same issue.