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

Vitest fixes #286

Merged
merged 3 commits into from
Jan 9, 2024
Merged

Vitest fixes #286

merged 3 commits into from
Jan 9, 2024

Conversation

Duddino
Copy link
Member

@Duddino Duddino commented Dec 21, 2023

Abstract

Vitest occasionally segfaulted. According to the docs, we were using the default multi threaded pool,

Enable multi-threading using tinypool [...] some libraries written in native languages, such as Prisma, bcrypt and canvas, have problems when running in multiple threads and run into segfaults. In these cases it is advised to use forks pool instead.

This PR changes the pool to fork, which should not have this issue. This incurs approximately a 10% decrease in performance.

Additionally, a setup file was added where we setup the happy-dom environment with the correct skeleton, instead of doing it each time per test.

Testing

Run npm test a bunch of times, and check that it doesn't segfaut

Copy link

netlify bot commented Dec 21, 2023

Deploy Preview for cheery-moxie-4f1121 ready!

Name Link
🔨 Latest commit 8fd9f42
🔍 Latest deploy log https://app.netlify.com/sites/cheery-moxie-4f1121/deploys/6583ee552eb20800088f057b
😎 Deploy Preview https://deploy-preview-286--cheery-moxie-4f1121.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@Duddino Duddino added the Bug This is either a bugfix (PR) or a bug (issue). label Dec 21, 2023
@Duddino Duddino self-assigned this Dec 21, 2023
Copy link
Member

@JSKitty JSKitty left a comment

Choose a reason for hiding this comment

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

tACK 8fd9f42

@Duddino Duddino merged commit 171afcf into PIVX-Labs:master Jan 9, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug This is either a bugfix (PR) or a bug (issue).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants