Skip to content

Run oxlint with a single thread - #7

Merged
lolgab merged 1 commit into
masterfrom
oxlint-cap-threads
Dec 3, 2026
Merged

lolgab merged 1 commit into
masterfrom
oxlint-cap-threads

Conversation

@lolgab

@lolgab lolgab commented Dec 3, 2026

Copy link
Copy Markdown
Contributor

oxlint sizes its thread pool from std::thread::available_parallelism() when --threads isn't given. Our tool pods have a memory limit but no CPU limit, so that's the whole node's core count (16–64), not the pod's 512m request. oxlint keeps one allocator arena per thread for the whole run, so on a big node it can hold that many parsed files at once against a 1Gi limit.

  • The wrapper now runs oxlint with --threads 1, matching the 512m CPU request.
  • oxlint ignores RAYON_NUM_THREADS, so the flag is the only way to set this (init_rayon_thread_pool at oxlint_v1.85.0).
  • Results don't change: the wrapper's output on both docs/multiple-tests fixtures is the same as on master (run locally with oxlint 1.85.0).

Same fix as codacy/codacy-opengrep#50; rule written up in codacy/claude-workbench#59.

  • After deploy, 7 days: oxlint ToolOutOfMemory count and run time p99 vs the 7 days before

@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 0 complexity · 0 duplication

Metric Results
Complexity 0
Duplication 0

View in Codacy

AI Reviewer: first review requested successfully. AI can make mistakes. Always validate suggestions.

Run reviewer

TIP This summary will be updated as you push new changes.

@lolgab
lolgab marked this pull request as ready for review December 3, 2026 10:25

@codacy-production codacy-production Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull Request Overview

✅ No blocking issues noticed

No blocking findings were identified.

Test suggestions

  • Verify the generated oxlint command includes --threads 1.
  • Run the wrapper against representative fixtures and verify diagnostics remain unchanged.
Prompt proposal for missing tests
Consider implementing these tests if applicable:
1. Verify the generated oxlint command includes --threads 1.
2. Run the wrapper against representative fixtures and verify diagnostics remain unchanged.

TIP Add review instructions in .codacy/instructions/review.md, or an AGENTS.md, so the reviewer knows your conventions.
TIP How was this review? Give us feedback

@lolgab
lolgab enabled auto-merge December 3, 2026 10:25
@lolgab
lolgab merged commit 2649487 into master Dec 3, 2026
4 checks passed
@lolgab lolgab mentioned this pull request Dec 3, 2026
3 tasks
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.

2 participants