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

Several tests fail on main with Node v16 #24915

Closed
0xdevalias opened this issue Jul 13, 2022 · 6 comments
Closed

Several tests fail on main with Node v16 #24915

0xdevalias opened this issue Jul 13, 2022 · 6 comments
Labels
Resolution: Stale Automatically closed due to inactivity Status: Unconfirmed A potential issue that we haven't yet confirmed as a bug

Comments

@0xdevalias
Copy link
Contributor

0xdevalias commented Jul 13, 2022

There was a previous issue opened for this, which had a solution implemented by @bvaughn to resolve, but there still seem to be some edgecases remaining:

It looks like there are a number of variations of ways that are currently being used to test that aren't captured by the changes made in #22477

I'll just include one example for each pattern variation I saw in my failed test runs:

packages/use-sync-external-store/src/__tests__/useSyncExternalStoreShared-test.js
    expect(received).toEqual(expected) // deep equality

    Expected: "Cannot read property 'toUpperCase' of undefined"
    Received: "Cannot read properties of undefined (reading 'toUpperCase')"
 packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js
    expect(received).toBe(expected) // Object.is equality

    Expected: "Cannot read property 'useState' of null"
    Received: "Cannot read properties of null (reading 'useState')"

So it looks like the other methods being used to test for this are .toEqual and .toBe

Originally posted by @0xdevalias in #22441 (comment)


Currently the CircleCI seems to only run tests on one node version (as I discovered while looking into #24891). I wonder if it would make sense to run them in the CI for all node versions include in the package.json devEngines.node; to proactively catch edgecases like this.

@eps1lon
Copy link
Collaborator

eps1lon commented Jul 14, 2022

Which specific node version is causing issues?

@eps1lon eps1lon added the Status: Unconfirmed A potential issue that we haven't yet confirmed as a bug label Jul 14, 2022
@0xdevalias
Copy link
Contributor Author

From the previous issue I linked:

I was on the latest NodeJS version (16.10.0). Note that tests pass for me when switching to the 14.x LTS release of Node.

@eps1lon
Copy link
Collaborator

eps1lon commented Jul 15, 2022

16.10 was released september 2021. Does the issue persist if you switch to the latest 16.x minor i.e. 16.16?

@0xdevalias
Copy link
Contributor Author

This is an issue with all 16.x and higher due to a change in the underlying error messages from node; as the previously linked issue describes in more detail, which is why I linked it for context on the issue..

Copy link

This issue has been automatically marked as stale. If this issue is still affecting you, please leave any comment (for example, "bump"), and we'll keep it open. We are sorry that we haven't been able to prioritize it yet. If you have any new additional information, please include it with your comment!

@github-actions github-actions bot added the Resolution: Stale Automatically closed due to inactivity label Apr 10, 2024
Copy link

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please create a new issue with up-to-date information. Thank you!

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Stale Automatically closed due to inactivity Status: Unconfirmed A potential issue that we haven't yet confirmed as a bug
Projects
None yet
Development

No branches or pull requests

2 participants