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

docs: add list of known incompatible npm packages #12892

Merged
merged 1 commit into from
Jan 9, 2023

Conversation

vkarpov15
Copy link
Collaborator

Fix #12671

Summary

#12671 is an issue with another npm package that adds some global properties which break an upstream dependency of Mongoose. It would be nice to have a list of known incompatible packages in our docs.

On a side note, it would be great to know which npm packages modify global state.

Examples

Copy link
Collaborator

@AbdelrahmanHafez AbdelrahmanHafez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks! 👍

Copy link
Collaborator

@hasezoey hasezoey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@hasezoey hasezoey added the docs This issue is due to a mistake or omission in the mongoosejs.com documentation label Jan 9, 2023
@Uzlopak
Copy link
Collaborator

Uzlopak commented Jan 9, 2023

I am personally against maintaining a potentially infintive list.

But I am ok with it.

@vkarpov15 vkarpov15 merged commit 456be2b into master Jan 9, 2023
@hasezoey hasezoey deleted the vkarpov15/gh-12671 branch January 9, 2023 18:26
@lorand-horvath
Copy link
Contributor

@vkarpov15 Wouldn't it be better for the mongodb driver to be fixed, so it doesn't make use of the conflicting globals that are being used/polluted by the collections package?
@Uzlopak is right. Maintaining a list of incompatible packages because of global namespace pollution is probably not future proof.

@vkarpov15
Copy link
Collaborator Author

@lorand-horvath maybe, or maybe better to fix the collections package. But good luck getting either collections (montagejs/collections#197) or whatwg-url (jsdom/webidl2js#255 (comment)) to budge on fixing their code.

In an ideal world, all code would fit nicely together. But unfortunately there's no practical way for us to fix either side without maintainer buy-in. collections.js hasn't had a significant update in 5 years and isn't likely to; whatwg-url is a bit rigid on accepting interop changes; and mongodb driver isn't open to switching off of whatwg-url. So this list is the best we can reasonably do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs This issue is due to a mistake or omission in the mongoosejs.com documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TypeError: Invalid URL while migrating from mongoose v5.10.0 to v6.7.2
5 participants