Open fretman92 opened 6 years ago
Thanks for the report; I look for this problem the next week.
Got same error on Linux with Electron 3.0.3, make app freezing.
The same problem after upgrading to electron 3.X.X
It seems there have been some changes in the stack of calls from the electron and I caught one interesting bug: I had a unpacked module with the joined paths, and paths after join was packed. But at the same time, if you wrap a join in a function (in the example, the map
is used), it makes the paths unpacked.
require('hazardous');
const path = require('path');
const config = {
scripts: ['some/script/path'],
};
const scriptsUrls = config.scripts.map(script => path.join(__dirname, script));
const scriptsUrls2 = [path.join(__dirname, config.scripts[0])];
console.log(scriptsUrls); // output: ['.../app.asar.unpacked/.../some/script/path']
console.log(scriptsUrls2); // output: ['.../app.asar/.../some/script/path']
In the second case, electron.asar
is present in the stack, because of this, the modules were considered packed
It began with electron 2.X.X and the same problem was preserved in electron 3.X.X. But now in electron 3.X.X the stack sometimes even comes null
I am getting a "Module did not self-register" error on start-up of the packaged app (win10 64bit) with electron 3.1.2. This error does not happen if remove callsite.
hazardous is broken since electron > 1. I've still not spend time on this.
Hello @Skywalker13 , thanks for maintening this package.
I'd like to report an error with the dependency
callsite
used. When installed and launched on some computers, Win10 and Win7 as well, hazardous is not working properly and throwing a fatal exception that crashes my electron app.Here is the stacktrace it logs:
I presume that
stack ()
is returningnull
or something like that, and I believe it should either be handled, or patched in the original package (I'll try to see with them as well).Has anybody faced the same problem and uncovered the reason why callsite does not return an array?