Describe the bug
The recent version of Copilot CLI appears to block access to the TEMP directory, which was previously allowed.
Affected version
0.0.340 Commit: fac8111
Steps to reproduce the behavior
I'm using Windows 10 with Windows Terminal with PowerShell 7 (pwsh.exe).
-
Create a C:\TEMP1 folder.
-
Change working directory to C:\TEMP1.
-
Create a test.ps1
echo '❌ An error occurred, please check the detailed log at: C:\TEMP\err.log'
echo '❌ An error occurred, please check the detailed log at: C:\TEMP\err.log'
-
Create a err.log to your $env:TEMP folder (I assume it's C:\TEMP folder) which is normally allowed by Copilot CLI.
-
Run the following command:
copilot --allow-all-tools -p 'Run test.ps1'
-
You will see the following:
✓ Run test.ps1 script
$ .\test.ps1
↪ 3 lines...
● The script ran but produced error messages. Let me check what's in the error log and the script
itself to understand what happened.
✓ Read test.ps1 (7 lines)
The following paths are outside the allowed directories:
- C:\TEMP\err.log
Allow access to these paths? (y/n):
Expected behavior
I expected to access any files in the TEMP folder without needing permission.
Additional context
- Operating system: Windows
- CPU architecture: x86_64
- Terminal emulator: Windows Terminal
- Shell: pwsh
Describe the bug
The recent version of Copilot CLI appears to block access to the TEMP directory, which was previously allowed.
Affected version
0.0.340 Commit: fac8111
Steps to reproduce the behavior
I'm using Windows 10 with Windows Terminal with PowerShell 7 (pwsh.exe).
Create a
C:\TEMP1folder.Change working directory to
C:\TEMP1.Create a
test.ps1Create a
err.logto your$env:TEMPfolder (I assume it'sC:\TEMPfolder) which is normally allowed by Copilot CLI.Run the following command:
You will see the following:
✓ Run test.ps1 script $ .\test.ps1 ↪ 3 lines... ● The script ran but produced error messages. Let me check what's in the error log and the script itself to understand what happened. ✓ Read test.ps1 (7 lines) The following paths are outside the allowed directories: - C:\TEMP\err.log Allow access to these paths? (y/n):Expected behavior
I expected to access any files in the TEMP folder without needing permission.
Additional context