Skip to content

On the required version of Node.js #33

@naiiren

Description

@naiiren

Environment

  • Typora: 1.12.4
  • OS: Ubuntu 25.10
  • Node.js: 22.12.0 (initially), works after upgrading to 25.7.0

Problem

This looks similar to #30 and #16: clicking Sign in to GitHub results in no visible action (no browser window, no login flow).

In the debugger, the SignInInitiate request returns an empty response {}. This does not appear to be a network issue.

Diagnosis

Running the bundled language server directly fails on Node 22.12.0:

node /usr/share/typora/resources/copilot/language-server/language-server.cjs

Output:

Error: No such built-in module: node:sqlite
    at Function._load (node:internal/modules/cjs/loader:1068:13)
    at TracingChannel.traceSync (node:diagnostics_channel:322:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:219:24)
    at Module.require (node:internal/modules/cjs/loader:1340:12)
    at require (node:internal/modules/helpers:138:16)
    at Object.<anonymous> (/usr/share/typora/resources/copilot/language-server/language-server.cjs:2232:25866)
    at Module._compile (node:internal/modules/cjs/loader:1565:14)
    at Object..js (node:internal/modules/cjs/loader:1708:10)
    at Module.load (node:internal/modules/cjs/loader:1318:32)
    at Function._load (node:internal/modules/cjs/loader:1128:12)

Suggestion

Upgrading Node.js to 25.7.0 resolves the issue (the sign-in flow works afterwards).

The README currently states only Node.js >= 20, but this failure suggests the Copilot language server may require a newer Node version (at least one that provides the node:sqlite built-in module, e.g., 22.22.0 LTS, check https://nodejs.org/api/sqlite.html).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions