Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Four problem loader browser tests fail on Windows

Closed Beginner friendly
#322 0 comments 0 reactions 1 assignee View on GitHub

Maintainers usually reply within 1 day

@Patriciaath999 is already working on this.

Since Oct 15, 2026.

  • #323 by @Patriciaath999 — merged

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
88/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
javascript, node.js
Domain
testing

Research direction

The four failing calls are in tests/browser/dom-contract.test.js at lines 157, 209, 227, 246 and 268, where absolute paths built with join(web, ...) are passed to import(). Read tests/browser/dom-hooks.js first, since it already converts paths with pathToFileURL from node:url, and apply the same pattern at those call sites. Done means the file reports 38 of 38 passing on Windows, with Linux CI still green.

Written by the indexing model from the issue text.

Description

On Windows, four tests in tests/browser/dom-contract.test.js fail before any assertion runs. The same tests pass on Linux CI.

  • problem loader resolves legacy ids and falls back to the default
  • an unreachable bank is reported as unreachable, not as an empty one
  • a page map that could not be fetched is asked for again
  • a judge that cannot be fetched is not a problem without tests

Environment: main at 6b6cdfe, Windows 11 Home (10.0.26200), Node v24.20.0.

Steps to reproduce:

  1. Check out main on Windows and run npm ci.
  2. Run node --test tests/browser/dom-contract.test.js.

Expected: 38 of 38 pass. Actual: 34 pass and 4 fail, each with:

Error [ERR_UNSUPPORTED_ESM_URL_SCHEME]: Only URLs with a scheme in: file, data, and node are supported by the default ESM loader. On Windows, absolute paths must be valid file:// URLs. Received protocol 'c:'

Code path: each test passes an absolute filesystem path to import(), built with join(web, ...). See tests/browser/dom-contract.test.js:157, :209, :227, :246 and :268 at 6b6cdfe. On Linux the path starts with / and the loader resolves it as a file. On Windows it starts with a drive letter, which the loader reads as the URL scheme c:. Converting the path with pathToFileURL(...).href from node:url gives a valid URL on both platforms. tests/browser/dom-hooks.js already uses this. I found no other import() of an absolute path under tests/.

Dominant language
Rust
Stars
160
Forks
64
Avg merge
1d 12h
Merged PRs (30d)
124

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from sysprog21/codetrial

All issues in sysprog21/codetrial

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.