Describe the bug
No response
Affected version
GitHub Copilot CLI v1.0.40
Steps to reproduce the behavior
Steps to reproduce:
- Ask Copilot CLI: "Generate a random 264-character base64 string and print it back"
OR paste a known string: eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IlUxc1g4WUZIUzdaNlZsN1ZITEl6VGVqYnZqMCIsImtpZCI6IlUxc1g4WUZIUzdaNlZsN1ZITEl6VGVqYnZqMCJ9.eyJzdWIiOiJ0ZXN0LXVzZXIiLCJhdWQiOiJo
dHRwczovL2V4YW1wbGUuY29tLyIsImV4cCI6OTk5OTk5OTk5OX0.AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
- Copy generated string and paste back to copilot
- Ask to count length
- Compare: original=264, returned=265
Expected behavior
String returned unchanged, length = 264
Additional context
OS: macOS
- Terminal: Terminal.app (confirmed: no tmux, echo $TMUX is empty)
- Shell: zsh
- CPU: Apple Silicon (ARM)
- The bug caused a real-world debugging loop: identical JWT Bearer token
worked in Postman (200 OK) but failed when pasted through Copilot CLI
chat (401 Unauthorized) because \n was silently inserted into the token,
corrupting the Authorization header.
- Workaround: save token to file via pbpaste > /tmp/token.txt and
read with $(cat /tmp/token.txt) instead of pasting through chat.
Describe the bug
No response
Affected version
GitHub Copilot CLI v1.0.40
Steps to reproduce the behavior
Steps to reproduce:
OR paste a known string: eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IlUxc1g4WUZIUzdaNlZsN1ZITEl6VGVqYnZqMCIsImtpZCI6IlUxc1g4WUZIUzdaNlZsN1ZITEl6VGVqYnZqMCJ9.eyJzdWIiOiJ0ZXN0LXVzZXIiLCJhdWQiOiJo
dHRwczovL2V4YW1wbGUuY29tLyIsImV4cCI6OTk5OTk5OTk5OX0.AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
Expected behavior
String returned unchanged, length = 264
Additional context
OS: macOS
worked in Postman (200 OK) but failed when pasted through Copilot CLI
chat (401 Unauthorized) because \n was silently inserted into the token,
corrupting the Authorization header.
read with $(cat /tmp/token.txt) instead of pasting through chat.