Skip to content

Fix rollup incompatibility, fix test failure #1208

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

Merged
merged 2 commits into from
Jun 23, 2025
Merged

Fix rollup incompatibility, fix test failure #1208

merged 2 commits into from
Jun 23, 2025

Conversation

powerivq
Copy link
Collaborator

@powerivq powerivq commented Jun 18, 2025

Build has been broken and npm install has not been working due to rollup plugin versions incompatible. Had to change to the newer version.

ava@3 no longer works with the dependencies. Tests always fail due to importing esm from dependencies. I had to upgrade to ava@6. This forces me to fix the ts imports since it is failing various tests. This PR seems to be the easiest way to fix it. It basically changes all imports to import xxx from 'xxx.js';

tsconfig is changed to module. Unit tests that use cb have been deprecated in ava, so I updated them to the promise-style tests.

I cannot neatly split it into PRs, since nothing is going to build till everything gets fixed.

@powerivq powerivq changed the title Fix rollup incompatibility Fix rollup incompatibility, fix test failure Jun 23, 2025
@powerivq powerivq self-assigned this Jun 23, 2025
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR addresses build and test failures caused by rollup plugin incompatibility by updating dependency versions and converting all TypeScript imports to include a “.js” extension in compliance with the newer ECMAScript module standards. In addition, the PR updates tsconfig settings (using nodenext and allowing TS extension imports) and revises test callbacks to use Promise‑resolution instead of t.end().

Reviewed Changes

Copilot reviewed 284 out of 287 changed files in this pull request and generated no comments.

File Description
src/worker-thread/tsconfig.json Updated module resolution and target to “nodenext” with additional TS flag
Various source files All import statements now include “.js” extensions to match ESM conventions
Multiple test files Modified test callbacks to return Promises instead of using t.end()
Comments suppressed due to low confidence (1)

src/worker-thread/tsconfig.json:10

  • The tsconfig.json has been updated to use 'nodenext' and includes 'allowImportingTsExtensions'. Please verify that these changes are fully compatible with your build process and dependency chain.
    "module": "nodenext",

@powerivq powerivq merged commit 6f71a7c into main Jun 23, 2025
5 checks passed
@powerivq powerivq deleted the fix-rollup branch June 23, 2025 21:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants