Add devproxy installation script and update .gitignore#1647
Conversation
| } | ||
| } catch(e) { | ||
| } catch (e) { | ||
| dbg(`failed to parse retry-after header as date: %s`, errorMessage(e)); |
There was a problem hiding this comment.
The function errorMessage(e) is used, but there is no import or definition for errorMessage in this file. This will cause a runtime error if errorMessage is not defined elsewhere in the scope.
AI-generated content by pr-review-commit
undefined_identifiermay be incorrect. Use reactions to eval.
| const agent = new ProxyAgent(proxy); | ||
| agent.on(`connect`, (info) => dbg(`connect: %s`, info.href)); | ||
| agent.on(`connectionError`, (err) => dbg(`connection error: %s`, err.toString())); | ||
| agent.on(`disconnect`, () => dbg(`disconnect`)); |
There was a problem hiding this comment.
The ProxyAgent from "undici" does not emit 'connect', 'connectionError', or 'disconnect' events. Attempting to attach event listeners to these events will have no effect and may cause confusion or runtime errors. Please refer to the "undici" documentation for supported events and usage.
AI-generated content by pr-review-commit
undici_proxyagent_event_apimay be incorrect. Use reactions to eval.
|
Caution The ProxyAgent from "undici" does not emit 'connect', 'connectionError', or 'disconnect' events. Attempting to attach event listeners to these events will have no effect and may cause confusion or runtime errors if the API changes. Please remove these event listeners or use supported mechanisms for monitoring agent activity.
|
| // We enrich crossFetch with the proxy. | ||
| const crossFetchWithProxy: typeof fetch = agent | ||
| ? (url, options) => crossFetch(url, { ...(options || {}), dispatcher: agent } as any) | ||
| ? (url, options) => crossFetch(url, { ...options, agent } as RequestInit) |
There was a problem hiding this comment.
The fetch agent is being set using the agent property in the options object, but cross-fetch does not support the agent property. This will have no effect and proxying will not work as intended.
| ? (url, options) => crossFetch(url, { ...options, agent } as RequestInit) | |
| ? (url, options) => crossFetch(url, { ...options, agent } as RequestInit) |
AI-generated content by pr-review-commit
incorrect_fetch_agent_optionmay be incorrect. Use reactions to eval.
| const agent = new ProxyAgent(proxy); | ||
| agent.on(`connect`, (info) => dbg(`connect: %s`, info.href)); | ||
| agent.on(`connectionError`, (err) => dbg(`connection error: %s`, err.toString())); | ||
| agent.on(`disconnect`, () => dbg(`disconnect`)); |
There was a problem hiding this comment.
The event listeners connect, connectionError, and disconnect are being attached to the undici ProxyAgent, but these are not standard events for undici's ProxyAgent and will not be triggered. This may cause confusion or missed debugging information.
| agent.on(`disconnect`, () => dbg(`disconnect`)); | |
| agent.on(`connect`, (info) => dbg(`connect: %s`, info.href)); |
AI-generated content by pr-review-commit
undici_proxyagent_event_namesmay be incorrect. Use reactions to eval.
| const { HttpsProxyAgent } = await import("https-proxy-agent"); | ||
| const agent = new HttpsProxyAgent(proxyUrl); | ||
| agent.on(`connect`, (info) => dbg(`connect: %s`, info.href)); | ||
| agent.on(`error`, (err) => dbg(`error: %s`, err.toString())); |
There was a problem hiding this comment.
The event listeners connect and error are being attached to the https-proxy-agent, but these are not standard events for this agent and will not be triggered. This may cause confusion or missed debugging information.
| agent.on(`error`, (err) => dbg(`error: %s`, err.toString())); | |
| agent.on(`connect`, (info) => dbg(`connect: %s`, info.href)); |
AI-generated content by pr-review-commit
https_proxy_agent_event_namesmay be incorrect. Use reactions to eval.
Investigator reportContext collection
AI AnalysisThe root cause of the failure is: The TypeScript compiler ( The commonality across all these errors is that types used from the Responsible codeHere are representative errors and sample code ranges affected: In In In Analysis
What is responsible:
Potential Fix
Example Fix (diff):Add project reference in File packages/vscode/tsconfig.json: {
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"outDir": "./dist",
"rootDir": "./src"
},
"references": [
{ "path": "../core" }
],
"include": ["src/**/*.ts"]
}Ensure File packages/core/tsconfig.json: {
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"composite": true,
"declaration": true,
"outDir": "./dist",
"rootDir": "./src"
},
"include": ["src/**/*.ts"]
}Summary The build failure is due to unresolved type references in
|
Introduce a script for installing devproxy and update .gitignore to exclude related directories.