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

jest expect failure error with BigInt #138

Closed
wilsonianb opened this issue Oct 5, 2021 · 3 comments · Fixed by #140 or #1541
Closed

jest expect failure error with BigInt #138

wilsonianb opened this issue Oct 5, 2021 · 3 comments · Fixed by #140 or #1541
Labels
pkg: backend Changes in the backend package. type: tests Testing related

Comments

@wilsonianb
Copy link
Contributor

This error is happening in our tests when an expect comparison of BigInts fails:
jestjs/jest#11617
It should be resolved by updating jest after this fix is merged and published:
jestjs/jest#11624

@wilsonianb wilsonianb added type: tests Testing related pkg: backend Changes in the backend package. labels Oct 5, 2021
@wilsonianb
Copy link
Contributor Author

I'm still encountering jest bigint serialization errors:

node:internal/child_process/serialization:120
    const string = JSONStringify(message) + '\n';
                   ^

TypeError: Do not know how to serialize a BigInt
    at stringify (<anonymous>)
    at writeChannelMessage (node:internal/child_process/serialization:120:20)
    at process.target._send (node:internal/child_process:812:17)
    at process.target.send (node:internal/child_process:710:19)
    at reportSuccess (/home/brandon/raio/.yarn/cache/jest-worker-npm-26.6.2-46cbcd449f-f9afa3b88e.zip/node_modules/jest-worker/build/workers/processChild.js:67:11)

This might actually need the linked fix.

@wilsonianb wilsonianb reopened this Oct 8, 2021
@bmarbury bmarbury added this to Rafiki Feb 24, 2022
@bmarbury bmarbury moved this to Blocked in Rafiki Feb 24, 2022
@matdehaast matdehaast added this to the Rafiki v1 milestone Aug 16, 2022
Repository owner moved this from Blocked to Done in Rafiki Dec 5, 2022
@wilsonianb
Copy link
Contributor Author

@wilsonianb wilsonianb reopened this Dec 5, 2022
@sabineschaller sabineschaller moved this from Done to Blocked in Rafiki Dec 20, 2022
@sabineschaller sabineschaller removed this from the Rafiki v1 milestone Jan 3, 2023
@sabineschaller
Copy link
Member

BigInts are serialized due to the use of multiple workers. That's why we don't run into test failures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: backend Changes in the backend package. type: tests Testing related
Projects
Archived in project
Status: Blocked
3 participants