Skip to content

script: implement import.meta.resolve#42506

Merged
TimvdLippe merged 3 commits intoservo:mainfrom
Gae24:import-meta-resolve
Feb 11, 2026
Merged

script: implement import.meta.resolve#42506
TimvdLippe merged 3 commits intoservo:mainfrom
Gae24:import-meta-resolve

Conversation

@Gae24
Copy link
Copy Markdown
Contributor

@Gae24 Gae24 commented Feb 10, 2026

Our implementation of HostGetImportMetaProperties wasn't providing resolve function to mozjs.

Testing: Covered by existing tests, results updated
Part of #37553

@Gae24 Gae24 requested a review from gterzian as a code owner February 10, 2026 13:12
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Feb 10, 2026
Copy link
Copy Markdown
Contributor

@TimvdLippe TimvdLippe left a comment

Choose a reason for hiding this comment

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

I am not an expert in mozjs side of things, but given the WPT results I think it's fine? Asked one question about the remaining test failures whether we can also address these in this PR or require more follow-up work.


[Scope sorting with multiple empty scopes: Multiple empty scopes before specific scope: Import from root bundles should use version1: bar]
expected: FAIL

[Scope sorting with multiple empty scopes: Multiple empty scopes before specific scope: Import from asdfasdf should use version1 (empty scope): bar]
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Is there any particular reason we are still failing those? Are those for other reasons than the current implementation?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I've not investigated it yet, but it's probably due to some corner case of resolve a module specifier that we are missing.

Copy link
Copy Markdown
Contributor

@TimvdLippe TimvdLippe left a comment

Choose a reason for hiding this comment

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

The code looks okay to me and given so many WPT tests start to pass, let's merge this. Do try to figure out in a follow-up how to fix the remaining test failures. Maybe there is an underlying issue that we can resolve (no pun intended).

@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Feb 11, 2026
@TimvdLippe TimvdLippe added this pull request to the merge queue Feb 11, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Feb 11, 2026
@TimvdLippe TimvdLippe removed this pull request from the merge queue due to a manual request Feb 11, 2026
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Feb 11, 2026
@TimvdLippe TimvdLippe added this pull request to the merge queue Feb 11, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Feb 11, 2026
Merged via the queue into servo:main with commit a83e197 Feb 11, 2026
36 checks passed
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Feb 11, 2026
@Gae24 Gae24 deleted the import-meta-resolve branch February 18, 2026 10:21
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.

3 participants