Coder Social home page Coder Social logo

Comments (3)

yhatt avatar yhatt commented on June 2, 2024

Related: vercel/pkg#1812

This error should not bring when executing from source code through npx @marp-team/[email protected] (Local installation).

from marp-cli.

jans-code avatar jans-code commented on June 2, 2024

This is not only an error with the linux binary.
I have this with the linux binary under Archlinux (same error as silkeh) and also with the windows binary.

pkg/prelude/bootstrap.js:1872
      throw error;
      ^

Error: File 'C:\**\marp-cli\node_modules\vm2\lib\setup-sandbox.js' was not included into executable at compilation stage. Please recompile adding it as asset or script.
    at error_ENOENT (pkg/prelude/bootstrap.js:657:19)
    at readFileFromSnapshot (pkg/prelude/bootstrap.js:1046:29)
    at Object.readFileSync (pkg/prelude/bootstrap.js:1094:18)
    at Object.<anonymous> (C:\snapshot\marp-cli\node_modules\vm2\lib\vm.js:148:57)
    at Module._compile (pkg/prelude/bootstrap.js:1926:22)
    at Module._extensions..js (node:internal/modules/cjs/loader:1166:10)
    at Module.load (node:internal/modules/cjs/loader:988:32)
    at Module._load (node:internal/modules/cjs/loader:834:12)
    at Module.require (node:internal/modules/cjs/loader:1012:19)
    at Module.require (pkg/prelude/bootstrap.js:1851:31) {
  errno: -4058,
  code: 'ENOENT',
  path: 'C:\\snapshot\\marp-cli\\node_modules\\vm2\\lib/setup-sandbox.js',
  pkg: true
}

Node.js v18.5.0

from marp-cli.

yhatt avatar yhatt commented on June 2, 2024

Probably a packaged binary by pkg is not yet available dynamic import for ESM.
vercel/pkg#1291

We must adopt the traditional way require() if Marp CLI is run via the standalone binary (Detectable with process.pkg). In this case, the engine cannot be ESM.

from marp-cli.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.