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

Nodes: Log warnings instead of throwing on redefinitions of Node types #27357

Conversation

hybridherbst
Copy link
Contributor

Description

Currently, when multiple versions of three are used (which is almost always accidental, yet can happen for example when using browser extensions that bring their own version of three.js), using Nodes leads to exceptions.

This PR downgrades those to warnings.
This is the same behaviour as three.js itself has when it's imported multiple times:

This contribution is funded by Needle

This is the same behaviour as three.js itself has when it's imported multiple times.
@mrdoob mrdoob requested a review from sunag December 12, 2023 10:47
@mrdoob mrdoob added this to the r160 milestone Dec 12, 2023
@sunag sunag merged commit f7102ac into mrdoob:dev Dec 12, 2023
11 checks passed
AdaRoseCannon pushed a commit to AdaRoseCannon/three.js that referenced this pull request Jan 15, 2024
mrdoob#27357)

This is the same behaviour as three.js itself has when it's imported multiple times.
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

Successfully merging this pull request may close these issues.

3 participants