aws / aws/aws-toolkit-vscode

PAC file support degraded after version 1.79

Open
#7,900 3 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
TypeScript
Stars
2k
Forks
807
Avg merge
10h 12m
Merged PRs (30d)
7

Description

## Problem

Many enterprises use PAC files as an integration method for corporate proxies and other enterprise security products. VSCode correctly supports PAC files, however, it appears that after version 1.79 support for PAC files was lost in the Amazon Q extension.

We have observed that the PAC file URL is being used as a Proxy URL, because the server that serves the PAC file is receiving `CONNECT` calls from Q:
```
::1 - - [15/Aug/2025 10:30:53] "CONNECT codewhisperer.us-east-1.amazonaws.com:443 HTTP/1.1" 501 -`
```
This behavior is entirely unexpected, and may reveal the problem area.

## Steps to reproduce the issue

1. Run a web proxy on port 8080.
2. Create PAC file named `local.pac`.
```
function FindProxyForURL(url, host) { return "PROXY 127.0.0.1:8080"; }
````
3. Serve PAC file by running local web server which serves files from the current directory:
```sh
python3 -m http.server 8082
```
4. Set system PAC file URL: `http://localhost:8082/local.pac`
5. Start VSCode.
6. Open Amazon Q chat.
7. Send message.
8. Observe return `Bad response: 501` in Amazon Q chat.
9. Observe Python web server serving PAC file outputs:
- `::1 - - [15/Aug/2025 10:30:53] code 501, message Unsupported method ('CONNECT')`
- `::1 - - [15/Aug/2025 10:30:53] "CONNECT codewhisperer.us-east-1.amazonaws.com:443 HTTP/1.1" 501 -`

## Expected behavior

Amazon Q should respect proxy configuration of client devices, specifically those who use PAC files to deploy those configurations.

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

- OS: `Darwin arm64 24.5.0`
- Visual Studio Code version: `1.103.1`
- AWS Toolkit version: `3.71.0`
- Amazon Q version: `1.80+`

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the issue with the listed PAC file, local proxy, and VS Code/Amazon Q versions, then trace the extension's proxy configuration handling. Done means Amazon Q respects the system PAC file, sends requests through the configured proxy, and the chat request succeeds instead of returning 501.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.