Skip to content

[BUG] Tests not running in CI #378

Closed

Description

@jamesnw

Describe the bug
The Test and Lint workflow is no longer running successfully in CI. The last successful run was December 1. Linting is successful, unit tests are successful, but e2e tests never run, and it times out after 6 hours.

First broken run was on this PR- #372

https://github.com/oddbird/css-anchor-positioning/actions/workflows/test.yml

Activity

  1. jamesnw commented on Feb 5, 2026

    @jamesnw
    ContributorAuthor

    Locally, it runs successfully in Node v24.11.1, and hangs in Node v24.12.0. Notably, type stripping is no longer experimental, so the flag is no longer --no-experimental-strip-types, but rather --no-strip-types.

    nodejs/node#60600

    However, I'm not convinced this isn't a red herring. On Node v24.12.0:

    • with --no-experimental-strip-types it hangs indefinitely
    • with --no-strip-types it hangs indefinitely
    • with neither, it immediately errors with SyntaxError: TypeScript enum is not supported in strip-only mode.

    The simplest way to get back up and running would be to hardcode the Node version to v24.11.1, but I'd rather fix the underlying issue.

    A related Playwright issue has some workarounds that I haven't found to work.

    @jgerigmeyer Do you have any thoughts on the underlying issue? Or should we just pin the Node version?

  2. break-stuff commented on Feb 9, 2026

    @break-stuff
    Contributor

    There are failing tests, but they are being masked by the script parallelization. I updated the task to stop when any of the scripts fail using the --race flag where run-p is called and I was able to see what was failing.

  3. jamesnw commented on Feb 9, 2026

    @jamesnw
    ContributorAuthor

    @break-stuff I'm curious about your methodology for discovering these issues.

    I'm able to reproduce the hang on Node v24.12.0 without any parallel tasks (Just running npm run test:e2e, which is NODE_OPTIONS='--no-experimental-strip-types' playwright test tests/e2e/).

    For the failing tests, where did you observe them failing? All e2e tests are passing locally on main on v24.11.1, and were passing recently in CI. Which branch and Node version did you see the tests failing?

  4. break-stuff commented on Feb 9, 2026

    @break-stuff
    Contributor

    When I ran the parts of the tests:ci individually, those were the tests that were failing for me.

  5. break-stuff commented on Feb 10, 2026

    @break-stuff
    Contributor

    Sorry, the node version I'm running is vv20.19.5.

  6. break-stuff commented on Feb 10, 2026

    @break-stuff
    Contributor

    Upgrading my node version resulted in another error regarding the enums, so I needed to include NODE_OPTIONS='--no-experimental-strip-types' in the test:e2e script. After replacing it, everything seems to be passing again.

    Could not parse CSS stylesheet
    Could not parse CSS stylesheet
    Could not parse CSS stylesheet
    
    SyntaxError: TypeScript enum is not supported in strip-only mode
    
        at eval (/Users/burtonsmith/Documents/Projects/css-anchor-positioning/<anonymous>:1:1)
    
    ···············*******························································
    ERROR: "test:e2e:ci" exited with 1.
    
  7. jamesnw commented on Feb 10, 2026

    @jamesnw
    ContributorAuthor

    After doing some spelunking into the Playwright source, it seems to be hanging at this line-

    https://github.com/microsoft/playwright/blob/a051ceb8e1302293ec42d4ad01d7f6325cbbfcf9/packages/playwright/src/transform/transform.ts#L209

    We have Playwright pinned so that we are testing old browser versions that need to be polyfilled. I suspect that Node 24.12 introduced a change that broke importing ESM modules in this way. Since we can't upgrade Playwright to a version that is compatible with Node 24.12, I think we need to pin our Node version to Node 24.11. I'll open a PR to test that out in CI.

  8. jamesnw commented on Feb 10, 2026

    @jamesnw
    ContributorAuthor

    @break-stuff I opened #379 to verify that pinning Node works as expected. It looks like adding --race was causing the e2e tests to fail silently, and never run.

  9. break-stuff commented on Feb 10, 2026

    @break-stuff
    Contributor

    Oh, interesting. Ok, I'll remove it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions