Skip to content

fix: add input validation for --max-iterations and --completion-promise args (GH#3816)#3832

Closed
marcusquinn wants to merge 1 commit intomainfrom
bugfix/quality-debt-pr14-critical
Closed

fix: add input validation for --max-iterations and --completion-promise args (GH#3816)#3832
marcusquinn wants to merge 1 commit intomainfrom
bugfix/quality-debt-pr14-critical

Conversation

@marcusquinn
Copy link
Owner

Summary

  • Add input validation for --max-iterations (must be positive integer) and --completion-promise (must be non-empty) across all loop helper argument parsers
  • Applies to ralph-loop-helper.sh (run_v2_loop, setup_loop) and quality-loop-helper.sh (preflight_loop, pr_review_loop, postflight_loop)
  • Also validates --max-attempts in run_v2_loop as a positive integer

Context

Addresses the remaining unactioned CodeRabbit review feedback from PR #14. Of the 6 original findings:

# Finding Status
1 postflight_loop silently ignores invalid --monitor-duration Fixed in prior PRs
2 aider branch sends prompt twice Fixed in #104
3 run_external_loop missing arg validation Fixed in this PR
4 get_repo_name fails in subdirectories Fixed in #480
5 Tool case branches hide failures with `
6 run_external_loop doesn't verify tool exists Fixed in #104

Closes #3816

…se args (GH#3816)

Address remaining unactioned CodeRabbit review feedback from PR #14:

- ralph-loop-helper.sh run_v2_loop: validate --max-iterations is a positive
  integer, --completion-promise is non-empty, --max-attempts is a positive
  integer. Previously these accepted any value silently.
- ralph-loop-helper.sh setup_loop: add matching validation for --max-iterations
  and --completion-promise for consistency.
- quality-loop-helper.sh: add --max-iterations validation to preflight_loop,
  pr_review_loop, and postflight_loop. All now reject non-positive-integer
  values with a clear error message instead of silently accepting them.

Other PR #14 findings (aider duplicate prompt, || true hiding failures, missing
tool existence check, invalid --monitor-duration, relative git_common_dir) were
already fixed in subsequent PRs #35, #104, #111, #396, #480.
@gemini-code-assist
Copy link

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@github-actions github-actions bot added the bug Auto-created from TODO.md tag label Mar 8, 2026
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 8, 2026

Warning

Rate limit exceeded

@marcusquinn has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 27 minutes and 58 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 4a538e51-b2b2-4d98-8cbe-2f09fe1b3570

📥 Commits

Reviewing files that changed from the base of the PR and between 339facd and 7f6639a.

📒 Files selected for processing (2)
  • .agents/scripts/archived/quality-loop-helper.sh
  • .agents/scripts/archived/ralph-loop-helper.sh
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch bugfix/quality-debt-pr14-critical

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 and usage tips.

@github-actions
Copy link

github-actions bot commented Mar 8, 2026

🔍 Code Quality Report

�[0;35m[MONITOR]�[0m Code Review Monitoring Report

�[0;34m[INFO]�[0m Latest Quality Status:
SonarCloud: 0 bugs, 0 vulnerabilities, 125 code smells

�[0;34m[INFO]�[0m Recent monitoring activity:
Sun Mar 8 01:30:41 UTC 2026: Code review monitoring started
Sun Mar 8 01:30:42 UTC 2026: SonarCloud - Bugs: 0, Vulnerabilities: 0, Code Smells: 125

📈 Current Quality Metrics

  • BUGS: 0
  • CODE SMELLS: 125
  • VULNERABILITIES: 0

Generated on: Sun Mar 8 01:30:44 UTC 2026


Generated by AI DevOps Framework Code Review Monitoring

@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 8, 2026

@marcusquinn
Copy link
Owner Author

@coderabbitai review

Review bots were rate-limited when this PR was created (affected: coderabbitai gemini-code-assist). Requesting a review retry.

@gemini-code-assist
Copy link

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 8, 2026

@marcusquinn: Sure! Kicking off a fresh review for PR #3832 now — sorry for the rate-limit delay! 🚀


🧠 Learnings used
Learnt from: marcusquinn
Repo: marcusquinn/aidevops PR: 0
File: :0-0
Timestamp: 2026-03-03T16:33:18.313Z
Learning: For the marcusquinn/aidevops repository: The daily quality sweep system (pulse-wrapper.sh) should only mention coderabbitai for full codebase review when there are significant changes (Quality Gate failure, +10 issues in one day, etc.), not on every automated sweep with stable metrics.
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@marcusquinn
Copy link
Owner Author

This PR appears orphaned — no active worker process found and no activity for 14+ hours. Flagging for re-dispatch. If work is still in progress, remove the status:orphaned label.

@marcusquinn
Copy link
Owner Author

Merging via pulse supervisor.

@marcusquinn
Copy link
Owner Author

Merge conflict detected — this PR cannot be auto-merged. The branch needs to be rebased onto main. Daily PR cap reached for today; will retry dispatch tomorrow.

@marcusquinn
Copy link
Owner Author

Closing — this PR has merge conflicts and touches too many files (blast radius issue, see t1422 / GH#3955). The underlying fixes will be re-created as smaller PRs (max 5 files each) to prevent conflict cascades.

Root cause: quality-debt batch PRs touching 10-69 files each created a conflict cascade where each merge invalidated the next PR's base. New rules cap quality-debt PRs at 5 files max and enforce serial merge ordering.

@marcusquinn marcusquinn closed this Mar 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Auto-created from TODO.md tag status:orphaned

Projects

None yet

Development

Successfully merging this pull request may close these issues.

quality-debt: PR #14 review feedback (critical)

1 participant