Skip to content

refactor(oxlint/lsp): accept multiple files inside LintRunner#16668

Merged
graphite-app[bot] merged 1 commit intomainfrom
12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_
Dec 16, 2025
Merged

refactor(oxlint/lsp): accept multiple files inside LintRunner#16668
graphite-app[bot] merged 1 commit intomainfrom
12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_

Conversation

@Sysix
Copy link
Member

@Sysix Sysix commented Dec 9, 2025

The Isolated linter from the language server stills sends only one file at the moment, but everything is ready to accept multiple files at the same time :)

@github-actions github-actions bot added A-linter Area - Linter A-editor Area - Editor and Language Server C-cleanup Category - technical debt or refactoring. Solution not expected to change behavior labels Dec 9, 2025
Copy link
Member Author

Sysix commented Dec 9, 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.

@codspeed-hq
Copy link

codspeed-hq bot commented Dec 9, 2025

CodSpeed Performance Report

Merging #16668 will not alter performance

Comparing 12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_ (584400d) with main (652a2bf)1

Summary

✅ 4 untouched
⏩ 41 skipped2

Footnotes

  1. No successful run was found on main (6b1a7b5) during the generation of this report, so 652a2bf was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

  2. 41 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 self-assigned this Dec 10, 2025
@Sysix Sysix force-pushed the 12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_ branch from 4e25873 to 87ba840 Compare December 10, 2025 21:44
@Sysix Sysix force-pushed the 12-09-refactor_linter_use_file_system_as_param_instead_of_source_text branch from 17dd958 to aee5bc6 Compare December 10, 2025 21:44
@Sysix Sysix requested a review from Copilot December 10, 2025 21:49
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 refactors the linting infrastructure to accept multiple files in the LintRunner and TsGoLintState APIs. While the language server currently still sends only one file at a time, the underlying infrastructure now supports batch processing of multiple files, preparing for future enhancements.

Key Changes

  • Modified LintRunner::run_source() to accept &[Arc<OsStr>] instead of a single file
  • Updated TsGoLintState::lint_source() to handle multiple files by reading all sources into a map and processing them together
  • Updated the isolated lint handler call site to use array syntax

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
crates/oxc_linter/src/lint_runner.rs Changed run_source() parameter from single file to files slice and updated calls to type-aware linter
crates/oxc_linter/src/tsgolint.rs Refactored lint_source() to loop through multiple paths, reading all sources into an override map for batch processing
crates/oxc_language_server/src/linter/isolated_lint_handler.rs Updated call site to wrap single path in array syntax

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Sysix Sysix force-pushed the 12-09-refactor_linter_use_file_system_as_param_instead_of_source_text branch from aee5bc6 to dd22b62 Compare December 10, 2025 22:46
@Sysix Sysix force-pushed the 12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_ branch from 87ba840 to fabb716 Compare December 10, 2025 22:46
@graphite-app graphite-app bot changed the base branch from 12-09-refactor_linter_use_file_system_as_param_instead_of_source_text to graphite-base/16668 December 13, 2025 12:39
@graphite-app graphite-app bot force-pushed the 12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_ branch from fabb716 to 9c5b63f Compare December 13, 2025 12:44
@graphite-app graphite-app bot force-pushed the graphite-base/16668 branch from dd22b62 to 73da317 Compare December 13, 2025 12:44
@graphite-app graphite-app bot changed the base branch from graphite-base/16668 to main December 13, 2025 12:44
@graphite-app graphite-app bot force-pushed the 12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_ branch from 9c5b63f to 4ed7478 Compare December 13, 2025 12:45
@Sysix Sysix force-pushed the 12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_ branch from 4ed7478 to 584400d Compare December 14, 2025 16:08
@Sysix Sysix marked this pull request as ready for review December 15, 2025 18:55
@Sysix Sysix requested a review from camc314 as a code owner December 15, 2025 18:55
@camc314 camc314 added the 0-merge Merge with Graphite Merge Queue label Dec 16, 2025
Copy link
Contributor

camc314 commented Dec 16, 2025

Merge activity

The Isolated linter from the language server stills sends only one file at the moment, but everything is ready to accept multiple files at the same time :)
@graphite-app graphite-app bot force-pushed the 12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_ branch from 584400d to 3e778fb Compare December 16, 2025 11:55
@graphite-app graphite-app bot merged commit 3e778fb into main Dec 16, 2025
21 checks passed
@graphite-app graphite-app bot deleted the 12-09-refactor_oxlint_lsp_accept_multiple_files_inside_lintrunner_ branch December 16, 2025 12:00
@graphite-app graphite-app bot removed the 0-merge Merge with Graphite Merge Queue label Dec 16, 2025
qinyuhang pushed a commit to qinyuhang/oxc that referenced this pull request Jan 22, 2026
…project#16668)

The Isolated linter from the language server stills sends only one file at the moment, but everything is ready to accept multiple files at the same time :)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-editor Area - Editor and Language Server A-linter Area - Linter C-cleanup Category - technical debt or refactoring. Solution not expected to change behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants