-
Notifications
You must be signed in to change notification settings - Fork 934
Closed
Description
Note: This issue was generated with AI assistance (GitHub Copilot).
Bug Report
Environment
- @github/copilot-sdk version: 0.1.29
- Node.js version: v24.3.0 (also tested on v24.14.0 LTS)
- OS: Windows 11
Description
@github/copilot-sdk fails to load on Node 24+ with ERR_MODULE_NOT_FOUND. The root cause is that the vscode-jsonrpc dependency uses extensionless ESM import specifiers (e.g., vscode-jsonrpc/node instead of vscode-jsonrpc/node.js), which Node 24's stricter ESM resolver rejects.
The SDK's README states Node.js >= 18.0.0 as a requirement, but it does not work on Node 24+. The CI tests only run against Node 22.
I've filed an upstream issue on vscode-jsonrpc: microsoft/vscode-languageserver-node#1740
Steps to Reproduce
- Install Node 24+ (e.g., v24.3.0 or v24.14.0 LTS)
npm install @github/copilot-sdk- Import and use the SDK
Error
Error [ERR_MODULE_NOT_FOUND]: Cannot find module '…/node_modules/vscode-jsonrpc/node' imported from …/node_modules/@github/copilot-sdk/dist/session.js
Did you mean to import "vscode-jsonrpc/node.js"?
at finalizeResolution (node:internal/modules/esm/resolve:274:11)
at moduleResolve (node:internal/modules/esm/resolve:859:10)
at defaultResolve (node:internal/modules/esm/resolve:983:11)
Expected Behavior
The SDK should either:
- Work on Node 24+ (by updating vscode-jsonrpc or patching imports)
- Document the Node version constraint accurately (e.g.,
>=18 <24) - Add Node 24 to the CI test matrix to catch this
Workaround
Use Node 22 LTS.
Related
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels