-
-
Notifications
You must be signed in to change notification settings - Fork 203
💥(worker) Drop CommonJS support #6488
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
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: d4f9b4e The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Co-authored-by: dubzzz <5300235+dubzzz@users.noreply.github.com>
@fast-check/ava
fast-check
@fast-check/jest
@fast-check/packaged
@fast-check/poisoning
@fast-check/vitest
@fast-check/worker
commit: |
|
👋 A preview of the new documentation is available at: http://6975056287e5dc0509fdc421--dubzzz-fast-check.netlify.app |
|
@copilot pull main and solve merge conflicts |
Co-authored-by: dubzzz <5300235+dubzzz@users.noreply.github.com>
|
@copilot please use the tricks described at faker-js/faker#3606 (comment) (see below for content) to fix the cjs runs of packages/jest/test-bundle and the tests in packages/jest/test when they require to use worker. Also update the doc of jest package to make it clear for users that they need to tweak their configs for jest to run with the worker thing Here is what the post says (adapt to our setup): Fix Steps; ✅ yarn add --dev babel-jest @babel/core @babel/preset-env jest.config.json "transform": { babel.config.js module.exports = { |
|
👋 A preview of the new documentation is available at: http://6979423e2eeca99164b74d5e--dubzzz-fast-check.netlify.app |
Co-authored-by: dubzzz <5300235+dubzzz@users.noreply.github.com>
I've added the Babel configuration as described in the Faker.js issue: What's working:
What's still failing:
The issue: The transformIgnorePatterns approach works for Faker because their files are in node_modules, but our worker package is symlinked outside node_modules, so the pattern doesn't apply. Next steps: |
|
@copilot revert your last change playing with jest |
Co-authored-by: dubzzz <5300235+dubzzz@users.noreply.github.com>
Done! Reverted all Jest-related changes from the last commit. Removed:
The PR now only contains the worker package CommonJS removal changes. (d4b41b6) |
|
👋 A preview of the new documentation is available at: http://697a88a7ab60d50a86fef35f--dubzzz-fast-check.netlify.app |
Removed test for property blocking the main thread due to potential infinite loop.
|
👋 A preview of the new documentation is available at: http://697b96a8ea337f1cd42b1bca--dubzzz-fast-check.netlify.app |
|
👋 A preview of the new documentation is available at: http://697b97ef3adaa42125025346--dubzzz-fast-check.netlify.app |
Plan: Drop CommonJS support from @fast-check/worker
Based on PR #6476 for the ava package, apply the same changes to the worker package:
package.cjs-template.jsonfilepackage.json:typesVersionsconfigurationmain,module, andtypesfieldstsconfig.jsonto usemodule: "node20"tsconfig.publish.jsonto usemodule: "node20"tsconfig.publish.types.jsonto usemodule: "node20"README.mdto reflect new Node version requirement (≥20.19.0 forrequire(esm)support).github/workflows/build-status.ymlto exclude worker from TypeScript checks for versions 5.0 and 5.7Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.