aws / aws/amazon-q-developer-cli

fs_read tool fails to handle symlinks properly in WSL

Open
#2,790 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
2k
Forks
439
PR merge metrics
No merged PRs in 30d

Description

Expected Behavior:
fs_read should be able to read directories through symlinks. When given a path like /home/USER/.aws that is a symlink to /mnt/c/Users/USER/.aws, it should follow the symlink and read the target directory.

Actual Behavior:
fs_read fails with error "Path is not a directory: ../../mnt/c/Users/USER/.aws" when trying to read a symlinked directory. The tool appears to be generating an invalid relative path instead of properly
resolving the symlink.

Steps to Reproduce:
1. In WSL environment, create a symlink: ln -s /mnt/c/Users/USER/.aws /home/USER/.aws
2. Try to read the symlinked directory with fs_read: {"mode": "Directory", "path": "/home/USER/.aws"}
3. Tool fails with symlink resolution error

Environment:
• OS: Linux 5.15.167.4-microsoft-standard-WSL2 - Ubuntu 24.04.3 LTS
• Q CLI version: 1.15.0
• In WSL: true

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.