Skip to content

fix(ci): compress bash_tests comment to hold the oversized-test ratchet - #212

Merged
KooshaPari merged 1 commit into
masterfrom
fix/test-size-ratchet-bash-tests
Oct 29, 2026
Merged

KooshaPari merged 1 commit into
masterfrom
fix/test-size-ratchet-bash-tests

Conversation

@KooshaPari

@KooshaPari KooshaPari commented Oct 29, 2026 •

Copy link
Copy Markdown
Owner

User description

Closes #211

Problem

The Enforce oversized-test ratchet CI gate failed on master.

  • Job: 122743035384 (master run 40666742839, head 1d8f6b28d, 2026-10-28)
  • Gate output: oversized test file grew: crates/jcode-app-core/src/tool/bash_tests.rs (1293 -> 1294 LOC)

The +1 line came from PR #194 (f2500f36c), which added the file-level
#![allow(clippy::await_holding_lock)] as line 1 of
crates/jcode-app-core/src/tool/bash_tests.rs. That attribute is required for the
workspace clippy gate to pass, so it cannot be removed.

Fix

Compress the neighbouring 5-line destructive-command-gate comment to 4 lines. This
restores the file to 1293 LOC, which is flat with its existing baseline entry in
scripts/test_size_budget.json.

This is a comment-only change:

  • no code, no cfg, no assertion is touched
  • scripts/test_size_budget.json is not modified, the baseline is not moved

Validation

$ python3 scripts/check_test_size_budget.py
Test-size budget OK: tracked=49 threshold=1200LOC
test_size_exit=0

$ python3 scripts/check_code_size_budget.py
Code-size budget improved: ...
code_size_exit=0

$ git show HEAD | grep -E '^[+-]' | grep -vE '^(\+\+\+|---)' | grep -vE '^[+-]\s*(//|$)' | wc -l
0

Diff stat: 1 file changed, 4 insertions(+), 5 deletions(-) — all comment lines.


CodeAnt-AI Description

Keep the bash test file within its existing size limit

What Changed

  • Condenses a test comment so the file stays at its existing line-count baseline and the oversized-test check passes.
  • No test logic or bash tool behavior changes.

Impact

✅ Existing oversized-test limit remains enforced
✅ Bash command behavior stays unchanged

💡 Usage Guide

Checking Your Pull Request

Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.

Talking to CodeAnt AI

Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:

@codeant-ai ask: Your question here

This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.

Example

@codeant-ai ask: Can you suggest a safer alternative to storing this secret?

Preserve Org Learnings with CodeAnt

You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:

@codeant-ai: Your feedback here

This helps CodeAnt AI learn and adapt to your team's coding style and standards.

Example

@codeant-ai: Do not flag unused imports.

Retrigger review

Ask CodeAnt AI to review the PR again, by typing:

@codeant-ai: review

Check Your Repository Health

To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.

The "Enforce oversized-test ratchet" gate failed because
crates/jcode-app-core/src/tool/bash_tests.rs grew from 1293 to 1294 LOC.
The extra line came from PR #194, which added the file-level
#![allow(clippy::await_holding_lock)] that is required for the workspace
clippy gate to pass.

Rather than move the ratchet baseline, compress the neighbouring 5-line
destructive-command-gate comment to 4 lines. This restores the file to
1293 LOC, so the file is flat with its existing baseline entry.

Comment-only change: no code, no cfg, no assertion touched.
scripts/test_size_budget.json is unmodified.

tx-agent: jcode
tx-validated: test
tx-task: test-size-ratchet-bash-tests
tx-scope: test
tx-intent: Keep the oversized-test ratchet green without moving the baseline
Copilot AI balanced review requested due to automatic review settings October 29, 2026 00:40
@codeant-ai

codeant-ai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

CodeAnt  CodeAnt Review Status

✅  Review completed

Status Commit Started (UTC) Finished (UTC)
✅  Reviewed your PR ea24d5c Oct 29, 2026 · 00:40 00:42

@codeant-ai

codeant-ai Bot commented Oct 29, 2026

Copy link
Copy Markdown

Thanks for using CodeAnt! 🎉

We're free for open-source projects. if you're enjoying it, help us grow by sharing.

Share on X ·
Reddit ·
LinkedIn

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

@codeant-ai codeant-ai Bot added the size:XS This PR changes 0-9 lines, ignoring generated files label Oct 29, 2026
@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 8ce087df-b21d-4f50-b851-a58a5e90c77d
Commits

Reviewing files that changed from the base of the PR and between 1d8f6b2 and ea24d5c.

Files selected for processing: 1
  • crates/jcode-app-core/src/tool/bash_tests.rs

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

Recent review details
Context from checks skipped due to timeout: 9
  • GitHub Check: Require Linked Issue
  • GitHub Check: Build & Test (desk-linux)
  • GitHub Check: TypeScript SDK
  • GitHub Check: Format
  • GitHub Check: Windows Cross-Target Check (Linux)
  • GitHub Check: Release Automation
  • GitHub Check: Quality Guardrails
  • GitHub Check: semgrep-cloud-platform/scan
  • GitHub Check: Kilo Code Review
Additional comments: 1
crates/jcode-app-core/src/tool/bash_tests.rs: 1

962-965: LGTM!

📝 Summary

Summary

This change shortens the destructive-command-gate comment in crates/jcode-app-core/src/tool/bash_tests.rs. The file is back at its 1293-line baseline. The change preserves the required #![allow(clippy::await_holding_lock)] attribute and does not alter executable code. The reported diff is comment-only.

Must Fix

None identified from the supplied evidence.

Should Fix

None identified from the supplied evidence.

Consider

The linked issue reports that python3 scripts/check_test_size_budget.py and python3 scripts/check_code_size_budget.py both pass. These results were not independently verified during this review.

Review finding counts are unavailable.

Approve / Request Changes

Approve. The change addresses the ratchet failure within the stated scope.

The pull request shortens and reformats the destructive-command-gate integration-test comment in bash_tests.rs. No executable code changes.

Changes: Test Comment

Layer / File(s) Summary
Destructive-command-gate comment
crates/jcode-app-core/src/tool/bash_tests.rs
The comment is shortened and reformatted. Its description of the gate tests’ coverage remains.

Priority: Low

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Bug fix

Possibly related PRs

  • KooshaPari/KCode#194: Adds the file-level lint allowance that increased the test file by one line.

Suggested reviewers: 1jehuang

Merge Risk: Minimal · up to ea24d

No actionable merge risk remains.

Pre-merge checks: Passed 5
Check name Status Explanation
Title check Passed The title clearly and concisely identifies the main change: compressing the bash test comment to satisfy the oversized-test CI ratchet.
Description check Passed The description directly explains the CI failure, the comment-only fix, the unchanged baseline, and the reported validation results.
Linked Issues check Passed Issue #211 requires the oversized-test ratchet to pass for crates/jcode-app-core/src/tool/bash_tests.rs. The file must return to its 1293 LOC baseline. The required line 1 attribute #![allow(clippy::a…
Out of Scope Changes check Passed The whole-PR diff changes one file: crates/jcode-app-core/src/tool/bash_tests.rs. All changed lines are comment lines (+4/-5). The change is directly tied to the size-ratchet objective in #211. No exe…
Docstring Coverage Passed No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Full details: Linked Issues check

Explanation

Issue #211 requires the oversized-test ratchet to pass for crates/jcode-app-core/src/tool/bash_tests.rs. The file must return to its 1293 LOC baseline. The required line 1 attribute #![allow(clippy::await_holding_lock)] must stay. The change must be comment-only, and scripts/test_size_budget.json must not change. The whole-PR diff against the merge base (1d8f6b2) shows one hunk at @@ -959,11 +959,10 @@. It condenses the destructive-command gate comment from 5 lines to 4. The head file still starts with #![allow(clippy::await_holding_lock)]. The diff touches no code, cfg, or assertion lines. Only one file changed, so scripts/test_size_budget.json is untouched. The net change is -1 line, which takes the file from 1294 (merge base, per the CI report) to 1293. The condensed comment keeps the original meaning: the unit policy lives in jcode-command-risk, the gate sits in the execute path, it refuses before spawning, and it does not disturb normal work. The check scripts were not run in this review. Their results rest on the PR description and the line arithmetic above.

Full details: Out of Scope Changes check

Explanation

The whole-PR diff changes one file: crates/jcode-app-core/src/tool/bash_tests.rs. All changed lines are comment lines (+4/-5). The change is directly tied to the size-ratchet objective in #211. No executable code, test logic, or configuration changed. No unrelated file changed, and the ratchet baseline file was not modified.

Full details: Docstring Coverage

Explanation

No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 1 files.

Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
✨ Simplify code
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@kilo-code-bot

kilo-code-bot Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (1 file)
  • crates/jcode-app-core/src/tool/bash_tests.rs

Fix these issues in Kilo Cloud


Reviewed by free · Input: 22.3K · Output: 874 · Cached: 146.5K

@codeant-ai

codeant-ai Bot commented Oct 29, 2026

Copy link
Copy Markdown

CodeAnt  CodeAnt PR Risk

🟢  Low Risk

  • The PR appears safe to merge; no actionable issues were identified in the review.

Assessed commit: ea24d5c66b0c

@KooshaPari
KooshaPari merged commit 19e24a3 into master Oct 29, 2026
14 of 17 checks passed
@KooshaPari
KooshaPari deleted the fix/test-size-ratchet-bash-tests branch November 26, 2026 11:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XS This PR changes 0-9 lines, ignoring generated files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(ci): oversized-test ratchet trips on bash_tests.rs because the await_holding_lock allow added one line

2 participants