Four problem loader browser tests fail on Windows
Maintainers usually reply within 1 day
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:
- Check out
mainon Windows and runnpm ci. - 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
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from sysprog21/codetrial
-
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
sysprog21/codetrial#318 · 3 comments · 2 reactions ·
Maintainers usually reply within 1 day
-
Candidate test cases persist across interviews for the same problem in the same tabPossibly taken @MZGamer claimed this 1 day ago. Open
sysprog21/codetrial#336 · 3 comments · 1 assignee ·
Maintainers usually reply within 1 day
-
A correct C solution to Clone Graph does not compilePossibly taken @Wu-1127 claimed this 1 day ago. Open
sysprog21/codetrial#332 · 1 assignee ·
Maintainers usually reply within 1 day
-
Run the live interviewer on a local speech pipelinePossibly taken @alanhc claimed this 1 day ago. Open
sysprog21/codetrial#330 · 1 assignee ·
Maintainers usually reply within 1 day
-
Let the candidate undo Continue without camera in the preflightPossibly taken @HALA1028 claimed this 2 days ago. Open
sysprog21/codetrial#327 · 1 comment · 1 assignee ·
Maintainers usually reply within 1 day
All issues in sysprog21/codetrial
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day
-
[Bug] ComponentType classifies 0x8A8A-0xEAEA as GREASE; mls-extensions §7.5 makes them private useOpen
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Maintainers usually reply within 1 day
-
area:ecosystem documentation
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Chelis-Lang/chelis#3866 ·
Maintainers usually reply within 1 day
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
metasequoiaime/msime#8620 ·
Maintainers usually reply within 1 day
-
agent-detection macos p2 triaged
Difficulty 1/5 Under an hour Newbie friendliness 90/100
Maintainers usually reply within 1 day