fix: ensure zx@lite pkg contents - #1317
Conversation
7131aad to
23ad886
Compare
There was a problem hiding this comment.
Pull Request Overview
This PR fixes package contents for the zx@lite distribution by ensuring proper file inclusion and updating test references to use CommonJS modules. The changes address issue #1316 related to packaging inconsistencies in the lite version of zx.
- Updates build scripts to use dynamic dependency detection for lite package contents
- Changes test imports from .js to .cjs files for consistency
- Updates dependency versions and build configuration
Reviewed Changes
Copilot reviewed 15 out of 18 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| test/vendor.test.js | Updates import to use vendor.cjs instead of vendor.js |
| test/util.test.js | Updates import to use util.cjs instead of util.js |
| test/package.test.js | Major restructure with new lite package testing and dynamic content verification |
| test/export.test.js | Updates imports to use .cjs files and removes vendor module tests |
| test/deps.test.js | Updates import to use deps.cjs instead of deps.js |
| test/core.test.js | Updates import to use util.cjs and adjusts timeout value |
| src/versions.ts | Updates depseek version from 0.4.1 to 0.4.3 |
| scripts/prepublish-lite.mjs | Implements dynamic file discovery using depseek for lite package contents |
| scripts/build-tests.mjs | Updates to use .cjs imports and removes vendor module |
| scripts/build-clean.mjs | New script to clean up redundant build files |
| package.json | Updates dependency versions and build configuration |
| build/vendor-extra.cjs | Code formatting changes with parentheses placement |
| build/vendor-core.cjs | Code formatting changes with parentheses placement |
| build/index.cjs | Updates depseek version and code formatting |
| .size-limit.json | Updates size limits to reflect package changes |
Comments suppressed due to low confidence (1)
test/package.test.js:111
- The removal of 'build/internals.d.ts' from the expected files list should be verified. If this file is no longer generated or included in the package, the test is correct. However, if this file should still be present, this could indicate a packaging issue that needs to be addressed.
'build/log.d.ts',
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.
| p2.pipe(p3) | ||
|
|
||
| setTimeout(() => p1.unpipe(p3), 180) | ||
| setTimeout(() => p1.unpipe(p3), 150) |
There was a problem hiding this comment.
[nitpick] The timeout value was reduced from 180ms to 150ms without explanation. This change could make the test more flaky on slower systems. Consider adding a comment explaining why this timing change was necessary or reverting to the original value if the change isn't essential to the fix.
| setTimeout(() => p1.unpipe(p3), 150) | |
| setTimeout(() => p1.unpipe(p3), 180) |
Fixes #1316