Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Error: HTMLWriter: prerendering failed on Windows (MODULE_NOT_FOUND) #2649

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Heptazhou
Copy link

┌ Error: HTMLWriter: prerendering failed
│   exception =
│    failed process: Process(`'~\scoop\apps\nodejs-lts\current\node.exe' -e "const hljs = require('~\AppData\Local\Temp\jl_42F8.tmp');
│    console.log(hljs.highlight(\"***\", {'language': \"julia\"}).value);
│    "`, ProcessExited(1)) [1]
│
│   stderr = "node:internal/modules/cjs/loader:1228\r\n  throw err;\r\n  ^\r\n\r\nError: Cannot find module '***AppDataLocalTempjl_42F8.tmp'\r\nRequire stack:\r\n- ***\\docs\\[eval]\r\n    at Function._resolveFilename (node:internal/modules/cjs/loader:1225:15)\r\n    at Function._load (node:internal/modules/cjs/loader:1055:27)\r\n    at TracingChannel.traceSync (node:diagnostics_channel:322:14)\r\n    at wrapModuleLoad (node:internal/modules/cjs/loader:220:24)\r\n    at Module.require (node:internal/modules/cjs/loader:1311:12)\r\n    at require (node:internal/modules/helpers:136:16)\r\n    at [eval]:1:14\r\n    at runScriptInThisContext (node:internal/vm:209:10)\r\n    at node:internal/process/execution:449:12\r\n    at [eval]-wrapper:6:24 {\r\n  code: 'MODULE_NOT_FOUND',\r\n  requireStack: [ '***\\\\docs\\\\[eval]' ]\r\n}\r\n\r\nNode.js v22.14.0\r\n"
└ @ Documenter.HTMLWriter ~\.julia\packages\Documenter\iwb7N\src\html\HTMLWriter.jl:2218
┌ Error: HTMLWriter: prerendering failed
│   exception =
│    failed process: Process(`'~\scoop\apps\nodejs-lts\current\node.exe' -e "const hljs = require('~\AppData\Local\Temp\jl_42F8.tmp');
│    console.log(hljs.highlight(\"***\", {'language': \"julia-repl\"}).value);
│    "`, ProcessExited(1)) [1]
│
│   stderr = "node:internal/modules/cjs/loader:1228\r\n  throw err;\r\n  ^\r\n\r\nError: Cannot find module '***AppDataLocalTempjl_42F8.tmp'\r\nRequire stack:\r\n- ***\\docs\\[eval]\r\n    at Function._resolveFilename (node:internal/modules/cjs/loader:1225:15)\r\n    at Function._load (node:internal/modules/cjs/loader:1055:27)\r\n    at TracingChannel.traceSync (node:diagnostics_channel:322:14)\r\n    at wrapModuleLoad (node:internal/modules/cjs/loader:220:24)\r\n    at Module.require (node:internal/modules/cjs/loader:1311:12)\r\n    at require (node:internal/modules/helpers:136:16)\r\n    at [eval]:1:14\r\n    at runScriptInThisContext (node:internal/vm:209:10)\r\n    at node:internal/process/execution:449:12\r\n    at [eval]-wrapper:6:24 {\r\n  code: 'MODULE_NOT_FOUND',\r\n  requireStack: [ '***\\\\docs\\\\[eval]' ]\r\n}\r\n\r\nNode.js v22.14.0\r\n"
└ @ Documenter.HTMLWriter ~\.julia\packages\Documenter\iwb7N\src\html\HTMLWriter.jl:2218
julia> let stderr = "node:internal/modules/cjs/loader:1228\r\n  throw err;\r\n  ^\r\n\r\nError: Cannot find module '***AppDataLocalTempjl_42F8.tmp'\r\nRequire stack:\r\n- ***\\docs\\[eval]\r\n    at Function._resolveFilename (node:internal/modules/cjs/loader:1225:15)\r\n    at Function._load (node:internal/modules/cjs/loader:1055:27)\r\n    at TracingChannel.traceSync (node:diagnostics_channel:322:14)\r\n    at wrapModuleLoad (node:internal/modules/cjs/loader:220:24)\r\n    at Module.require (node:internal/modules/cjs/loader:1311:12)\r\n    at require (node:internal/modules/helpers:136:16)\r\n    at [eval]:1:14\r\n    at runScriptInThisContext (node:internal/vm:209:10)\r\n    at node:internal/process/execution:449:12\r\n    at [eval]-wrapper:6:24 {\r\n  code: 'MODULE_NOT_FOUND',\r\n  requireStack: [ '***\\\\docs\\\\[eval]' ]\r\n}\r\n\r\nNode.js v22.14.0\r\n"
       print(stderr)
       end
node:internal/modules/cjs/loader:1228
  throw err;
  ^

Error: Cannot find module '***AppDataLocalTempjl_42F8.tmp'
Require stack:
- ***\docs\[eval]
    at Function._resolveFilename (node:internal/modules/cjs/loader:1225:15)
    at Function._load (node:internal/modules/cjs/loader:1055:27)
    at TracingChannel.traceSync (node:diagnostics_channel:322:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:220:24)
    at Module.require (node:internal/modules/cjs/loader:1311:12)
    at require (node:internal/modules/helpers:136:16)
    at [eval]:1:14
    at runScriptInThisContext (node:internal/vm:209:10)
    at node:internal/process/execution:449:12
    at [eval]-wrapper:6:24 {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '***\\docs\\[eval]' ]
}

Node.js v22.14.0
(docs) pkg> status Documenter
Status `***\docs\Project.toml`
  [e30172f5] Documenter v1.8.1

Ref: #1627.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant