Skip to content

Conversation

@camc314
Copy link
Contributor

@camc314 camc314 commented Oct 13, 2025

No description provided.

Copy link
Contributor Author

camc314 commented Oct 13, 2025


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions github-actions bot added A-linter Area - Linter A-cli Area - CLI labels Oct 13, 2025
@camc314 camc314 changed the title add repro DRAFT: fix(oxlint): extends relative custom plugin fail Oct 13, 2025
@codspeed-hq
Copy link

codspeed-hq bot commented Oct 15, 2025

CodSpeed Performance Report

Merging #14556 will not alter performance

Comparing c/10-13-add_repro (55becc5) with main (6bb9902)

Summary

✅ 4 untouched
⏩ 33 skipped1

Footnotes

  1. 33 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@camc314 camc314 changed the title DRAFT: fix(oxlint): extends relative custom plugin fail fix(oxlint): resolving JS plugin failing when extends is used Oct 15, 2025
@github-actions github-actions bot added the C-bug Category - Bug label Oct 15, 2025
@camc314 camc314 assigned camc314 and overlookmotel and unassigned camc314 Oct 15, 2025
@camc314 camc314 force-pushed the c/10-13-add_repro branch 3 times, most recently from 69c8965 to bc14d64 Compare October 15, 2025 12:51
@camc314 camc314 marked this pull request as ready for review October 15, 2025 12:51
Copilot AI review requested due to automatic review settings October 15, 2025 12:51
Copy link
Contributor

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 fixes an issue where JS plugin loading fails when configuration files use the extends feature. The fix involves changing how external plugins are handled internally to track both their specifiers and the directory containing the configuration file that references them.

Key changes:

  • Removed the default null value for jsPlugins in schema files to fix serialization issues
  • Modified external plugin storage to include configuration directory paths alongside plugin specifiers
  • Updated plugin resolution logic to use the correct directory for relative plugin paths

Reviewed Changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tasks/website/src/linter/snapshots/schema_markdown.snap Removes default null value from jsPlugins documentation
npm/oxlint/configuration_schema.json Removes default null value from jsPlugins schema
crates/oxc_linter/src/snapshots/schema_json.snap Removes default null value from jsPlugins schema
crates/oxc_linter/src/config/oxlintrc.rs Adds custom serialization/deserialization and path tracking for external plugins
crates/oxc_linter/src/config/overrides.rs Adds custom serialization/deserialization for external plugins in overrides
crates/oxc_linter/src/config/config_builder.rs Updates plugin loading logic to use configuration directory paths
apps/oxlint/test/fixtures/custom_plugin_nested_config/* Adds test fixtures for nested configuration scenario
apps/oxlint/test/e2e.test.ts Adds test case for custom plugin with nested config
apps/oxlint/src/snapshots/* Updates snapshots to reflect removal of default null values

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Copy link
Member

@overlookmotel overlookmotel left a comment

Choose a reason for hiding this comment

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

I'm a bit confused by the Option<PathBuf> - please see comments below.

I'm also unsure if we've introduced the possibility of same plugin getting loaded twice, because ("/foo/bar", "./plugin.js") and ("/foo/bar/qux", "../plugin.js") resolve to the same path, but do not hash the same.

But even if the latter is possible, it's an edge case, so I think we could merge this and deal with that oddity in a later PR.

@camc314
Copy link
Contributor Author

camc314 commented Oct 15, 2025

m also unsure if we've introduced the possibility of same plugin getting loaded twice, because ("/foo/bar", "./plugin.js") and ("/foo/bar/qux", "../plugin.js") resolve to the same path, but do not hash the same.

But even if the latter is possible, it's an edge case, so I think we could merge this and deal with that oddity in a later PR.

let me add a test in a follow up PR. i've got no idea. EDIT: looks like we handle this already, but i added a test in the follow up to prevent any regressions

Option<PathBuf> is gone! it looks much better now.

@camc314 camc314 force-pushed the c/10-13-add_repro branch 2 times, most recently from 6c30cc9 to 55becc5 Compare October 15, 2025 22:19
@camc314 camc314 added the 0-merge Merge with Graphite Merge Queue label Oct 20, 2025
Copy link
Contributor Author

camc314 commented Oct 20, 2025

Merge activity

@camc314 camc314 assigned camc314 and unassigned overlookmotel Oct 20, 2025
@graphite-app graphite-app bot force-pushed the c/10-13-add_repro branch from 55becc5 to 28e76ec Compare October 20, 2025 10:03
@graphite-app graphite-app bot merged commit 28e76ec into main Oct 20, 2025
20 checks passed
@graphite-app graphite-app bot deleted the c/10-13-add_repro branch October 20, 2025 10:08
@graphite-app graphite-app bot removed the 0-merge Merge with Graphite Merge Queue label Oct 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-cli Area - CLI A-linter Area - Linter C-bug Category - Bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants