Closed marekventur closed 7 years ago
Have you done an npm i since the last release? As it added a build step in
@themoonrat: yes, that how I got the new version in the first place. Our jenkins does a fresh build every time and gets the same error.
ah ok. Haven't actually done a new build on 2.1.0 yet, but adding pixify for the build stage is what would have caused it
I redid my npm install, and didn't have a problem building or running the examples afterwards. Is the error you are getting during npm run build
or when trying to use the library after building?
npm install
works without a problem, it's when we run browserify that an error gets thrown:
00:07:10.535 [14:34:10] Starting 'browserify'...
00:07:16.695 events.js:141
00:07:16.695 throw er; // Unhandled 'error' event
00:07:16.695 ^
00:07:16.695
00:07:16.695 Error: Cannot find module './ParticleUtils' from '/var/lib/jenkins/jobs/game-master/workspace/node_modules/pixi-particles/dist'
00:07:16.695 at /var/lib/jenkins/jobs/game-master/workspace/node_modules/browserify/node_modules/browser-resolve/node_modules/resolve/lib/async.js:55:21
00:07:16.695 at load (/var/lib/jenkins/jobs/game-master/workspace/node_modules/browserify/node_modules/browser-resolve/node_modules/resolve/lib/async.js:69:43)
00:07:16.695 at onex (/var/lib/jenkins/jobs/game-master/workspace/node_modules/browserify/node_modules/browser-resolve/node_modules/resolve/lib/async.js:92:31)
00:07:16.695 at /var/lib/jenkins/jobs/game-master/workspace/node_modules/browserify/node_modules/browser-resolve/node_modules/resolve/lib/async.js:22:47
00:07:16.695 at FSReqWrap.oncomplete (fs.js:82:15)
I can try to reduce it down to a minimal example, but I was hoping the problem would be obvious from the description :(
Ah, you are trying to browserify pixi-particles into your code? I haven't used browserify too much - are there any known problems with browserifying a browserified library?
generally not, at least none I'm aware of.
It is indeed a known issue without an official solution: https://github.com/substack/node-browserify/pull/1151. http://stackoverflow.com/a/28176927 provides some workaround suggestions.
I didn't expect that. Thanks for digging this out, I'll see what I can do. I guess this means I can close this issue?
Yep, although would like to know which workaround works best (for you).
I'll keep you posted - although I doubt I'll have much time to poke it this week :(
it's 2017, and seems like browserify would need a derequire pass to rename all require() calls in the bundle so that browserify skips module loading.
derequire added in 2.1.7, see if that helps?
Since 2.1.0 I'm getting
when trying to build a project with pixi-particles. I've looked through the changeset, but I couldn't find what has caused this problem. Any ideas?