Error: Cannot mkdir in a snapshot. Try mountpoints instead.
See original GitHub issueWhat version of pkg are you using?
5.6.0
What version of Node.js are you using?
v16.15.0
What operating system are you using?
Windows 10
What CPU architecture are you using?
x86_64
What Node versions, OSs and CPU architectures are you building for?
default
Describe the Bug
i am compiling “macaca-cli” repository, and it is compiling successfully into exe. but when i run the application it gives me this error
pkg/prelude/bootstrap.js:1833
throw error;
^
Error: Cannot mkdir in a snapshot. Try mountpoints instead.
at mkdirFailInSnapshot (pkg/prelude/bootstrap.js:1593:7)
at Object.mkdirSync (pkg/prelude/bootstrap.js:1605:12)
at Object.sync [as mkdir] (C:\snapshot\macaca-cli-master\node_modules\mkdirp\index.js:74:13)
at Logger._init (C:\snapshot\macaca-cli-master\node_modules\xlogger\lib\xlogger.js:44:5)
at new Logger (C:\snapshot\macaca-cli-master\node_modules\xlogger\lib\xlogger.js:40:8)
at Object.<anonymous> (C:\snapshot\macaca-cli-master\node_modules\xlogger\lib\xlogger.js:172:18)
at Module._compile (pkg/prelude/bootstrap.js:1887:22)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1157:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
Expected Behavior
It should run the compiled app
To Reproduce
just compile “macaca-cli” repository and run it.
Issue Analytics
- State:
- Created a year ago
- Comments:8
Top Results From Across the Web
Cannot mkdir in a snapshot. Try mount points instead.
I solved this problem by using process.cwd() to get your pkg execute path, which you can use this to create new dir. Because...
Read more >Docker tries to mkdir the folder that I mount
The problem was that by default the CryFS-mounted virtual directory is not accessible by root , but Docker runs as root . The...
Read more >Mount successful, Directory accessible, but cannot do ...
I was able to mount the folder, but cannot do file operations. ... Note: if i am using sudo mkdir it is allowing...
Read more >Cannot mount /.snapshots to @snapshots
I am trying to get my Snapper Snapshot layout as per Arch Wiki. I have now deleted the original /.snapshots folder, created a...
Read more >Can't seem to mount a snapshot
Can't seem to mount a snapshot. I'm running the latest Mojave. I create a snapshot with: $ tmutil localsnapshot Created local snapshot with ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
BTW the error IMO is here:
I think this
xlogger
module by default stores the log or else in a directory inside node_modules folderhttps://github.com/xudafeng/xlogger/blob/master/lib/xlogger.js#L44
Seems it’s configurable with options so maybe a patch isn’t needed here.
you should write a patch for npm-update
See example here