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

Multiple package definitions error #124

Open
christosf opened this issue Feb 23, 2024 · 6 comments
Open

Multiple package definitions error #124

christosf opened this issue Feb 23, 2024 · 6 comments

Comments

@christosf
Copy link

christosf commented Feb 23, 2024

W20240223-14:23:38.579(2)? (STDERR) ⚡ Detected multiple package definitions within eventemitter3! Please report this to https://github.com/JorgenVatle/meteor-vite/issues

W20240223-14:23:38.580(2)? (STDERR) ⚡ Package ostrio:files was defined within eventemitter3 🤔

I get the above error and the frontend will not load. It says to report this issue here.

Screenshot 2024-02-23 160100

Screenshot 2024-02-23 160148

@JorgenVatle
Copy link
Owner

Hey there! 👋

What version of meteor-vite and jorgenvatle:vite-bundler are you using? If you could set up a project reproducing the issue, that would be tremendously helpful. 🙌

@JorgenVatle
Copy link
Owner

Just following up, are you still having issues with this?

@dallman2
Copy link

Same issue as in #145 and #151 .

I am using versions:

meteor-vite: ^1.10.2
jorgenvatle:vite-bundler@2.0.0-beta.14 (i cloned the meteor 3 migration branch)

@timsun28
Copy link

timsun28 commented Oct 1, 2024

I'm having the exact same issue regarding the ostrio:files package. I tried to recreate the issue in an empty project, but I'm not able to for some reason. I tried installing all the same packages as my private project, but it still runs without issues. I have tried meteor reset and removed node_modules etc without any luck in my private project.

Did anyone else find a solution regarding this package?

Strangely enough I'm not having this issue on the meteor-vite 1.10.4 and jorgenvatle:vite-bundler@2.0.3.
But when I'm updating to meteor-vite "^2.0.0-next.1" and jorgenvatle:vite-bundler@3.0.0-meteor3.next.11 the issue starts.

I would be available for quick call or help in another way to find a solution for this issue.

@JorgenVatle
Copy link
Owner

Hey there.

If you're able to, could you send me the full stack traces and error messages so I can have a closer look? 🙏

@timsun28
Copy link

timsun28 commented Oct 3, 2024

Hi,

I was able to reproduce it by importing the file collection on the client side and after loading the page in the browser.

I still have some error traces here:

W20241003-17:19:15.082(2)? (STDERR) ⚡  Detected multiple package definitions within eventemitter3! Please report this to https://github.com/JorgenVatle/meteor-vite/issues
W20241003-17:19:15.082(2)? (STDERR) ⚡  Package ostrio:files was defined within eventemitter3 🤔
W20241003-17:19:15.086(2)? (STDERR) 5:19:15 PM [vite] Internal server error: 
W20241003-17:19:15.086(2)? (STDERR)  ERROR  Could not locate 'index.js' in package!
W20241003-17:19:15.087(2)? (STDERR) undefined
W20241003-17:19:15.087(2)? (STDERR) 
W20241003-17:19:15.087(2)? (STDERR) --[Error Stack]----------------------------------------------------------------------
W20241003-17:19:15.087(2)? (STDERR)       at get mainModule [as mainModule] (/Users/timo.frionnet/Github-projects/vite-files-bug/node_modules/meteor-vite/dist/plugin/index.js:1549:13)
W20241003-17:19:15.088(2)? (STDERR)       at _MeteorPackage.getModule (/Users/timo.frionnet/Github-projects/vite-files-bug/node_modules/meteor-vite/dist/plugin/index.js:1489:19)
W20241003-17:19:15.089(2)? (STDERR)       at _MeteorPackage.serialize (/Users/timo.frionnet/Github-projects/vite-files-bug/node_modules/meteor-vite/dist/plugin/index.js:1562:28)
W20241003-17:19:15.090(2)? (STDERR)       at _MeteorPackage.toJson (/Users/timo.frionnet/Github-projects/vite-files-bug/node_modules/meteor-vite/dist/plugin/index.js:1479:26)
W20241003-17:19:15.090(2)? (STDERR)       at storeDebugSnippet (/Users/timo.frionnet/Github-projects/vite-files-bug/node_modules/meteor-vite/dist/plugin/index.js:1912:66)
W20241003-17:19:15.090(2)? (STDERR)       at async Context.load (/Users/timo.frionnet/Github-projects/vite-files-bug/node_modules/meteor-vite/dist/plugin/index.js:1897:9)
W20241003-17:19:15.090(2)? (STDERR)       at async Object.load (file:///Users/timo.frionnet/Github-projects/vite-files-bug/node_modules/vite/dist/node/chunks/dep-b2890f90.js:44323:32)
W20241003-17:19:15.090(2)? (STDERR)       at async loadAndTransform (file:///Users/timo.frionnet/Github-projects/vite-files-bug/node_modules/vite/dist/node/chunks/dep-b2890f90.js:54954:24)
W20241003-17:19:15.091(2)? (STDERR) 
W20241003-17:19:15.091(2)? (STDERR)  ERROR  Could not locate 'index.js' in package!
W20241003-17:19:15.091(2)? (STDERR) undefined
W20241003-17:19:15.091(2)? (STDERR) 
W20241003-17:19:15.092(2)? (STDERR) --[Error Stack]----------------------------------------------------------------------

This can be reproduced by using the ostrio:files-bug branch on this repo

Let me know if you are able to get it working and can find a fix.

Thank you!

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

No branches or pull requests

4 participants