Skip to content

gmgn-cli crashes on Node 18 despite engines.node advertising >=18.0.0 #25

@deepfeature

Description

@deepfeature

Summary

package.json currently advertises Node >=18.0.0, but the dependency set includes undici@^7.24.1, which requires Node >=20.18.1.

As a result, the CLI crashes on Node 18 before it can execute a request.

Relevant source:

  • package.json: "undici": "^7.24.1"
  • package.json: "engines": { "node": ">=18.0.0" }

Reproduction

Environment:

  • Node v18.16.1
  • npm 9.5.1

Steps:

  1. Run npm ci
  2. Run npx --no-install tsx src/index.ts market trending --chain sol --interval 1h --limit 10 --raw

Actual behavior

The command crashes with:

/Users/.../node_modules/undici/lib/web/webidl/index.js:537
webidl.is.File = webidl.util.MakeTypeAssertion(File)
                                               ^

ReferenceError: File is not defined

Expected behavior

One of the following should be true:

  • the package works on Node 18 as declared, or
  • the supported Node version is raised in package.json and documentation to match the actual runtime requirement.

Suggested fixes

  • Pin undici to a Node-18-compatible version, or
  • Raise the minimum supported Node version to 20.18.1+ and update the docs/examples accordingly.

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