Ignore native bounty ids in queue refs#547
Conversation
Bounty ramimbo#427: scripts/pr_queue_health.py
Bounty ramimbo#427: tests/test_pr_queue_health.py
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughExpanded the bounty-reference regex to detect more keywords while excluding native-like prefixed "bounty" mentions; updated the missing-bounty message to include "Issue #"; added/adjusted tests to validate mixed native/issue-reference scenarios and markdown formatting. ChangesBounty Reference Parsing
Possibly Related PRs
🚥 Pre-merge checks | ✅ 6✅ Passed checks (6 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: c075eaa7-7daa-426e-b4ea-dea56fe7d5a7
📒 Files selected for processing (2)
scripts/pr_queue_health.pytests/test_pr_queue_health.py
Baijack-star
left a comment
There was a problem hiding this comment.
I found one correctness issue that still leaves the advertised native-id case noisy.
The new pattern only suppresses live bounty #... and MRWK bounty #..., but the PR title and summary describe ignoring native bounty ids in general. A body that uses the natural wording native bounty #66 / issue #406 still matches bounty #66, so analyze_queue emits unknown_bounty_reference even though the GitHub issue ref is present.
Repro I ran on this branch:
PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 ./.venv/bin/python - <<'PY'
from scripts.pr_queue_health import analyze_queue
fixture = {
"bounties": [{"number": 406, "state": "OPEN", "awards_remaining": 16}],
"pull_requests": [{
"number": 547,
"title": "Refs #406: Ignore native bounty ids",
"body": "Evidence: native bounty #66 / issue #406 preflight returned status=open.",
"merge_state": "clean",
"labels": [],
}],
}
report = analyze_queue(fixture)
print(report["summary"])
print(report["closed_bounty_references"])
PYObserved:
{'pull_requests': 1, 'open_bounties': 1, 'closed_or_exhausted_bounties': 0, 'closed_bounty_references': 1, 'missing_bounty_references': 0, 'dirty_or_unstable_merge_state': 0, 'needs_info': 0, 'duplicate_scope_groups': 0}
[{'pull_request': 547, 'title': 'Refs #406: Ignore native bounty ids', 'url': None, 'reason': 'unknown_bounty_reference', 'detail': 'Referenced bounty #66 was not in input'}]
The focused suite itself passes (PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 ./.venv/bin/python -m pytest tests/test_pr_queue_health.py -q, 10 passed), so this likely needs an added regression case and either a broader native-id prefix list or parsing that prefers explicit issue/refs/fixes/closes/claims references over generic native bounty evidence text.
|
Addressed the requested-change case in the updated PR head What changed:
Repro from the review now returns no queue-health finding: Validation after the update:
|
Baijack-star
left a comment
There was a problem hiding this comment.
Thanks for the update. I rechecked the requested-change case on head db9e5e9fafbf22fc9426a8ac78773a31e740cd24; the native/internal wording that failed before is now covered and resolves cleanly to the GitHub issue reference.
Validation run locally:
PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 ./.venv/bin/python -m pytest tests/test_pr_queue_health.py -q-> 10 passed./.venv/bin/python -m ruff check scripts/pr_queue_health.py tests/test_pr_queue_health.py-> passed./.venv/bin/python -m ruff format --check scripts/pr_queue_health.py tests/test_pr_queue_health.py-> passedgit diff --check origin/main...HEAD-> clean
I also reran the ad hoc parser smoke for these bodies and each produced zero closed_bounty_references and zero missing_bounty_references:
native bounty #66 / issue #406internal bounty #66, issue #406MRWK bounty #66 / issues #406live bounty #66 / issue #406
No remaining blocker from my earlier requested-change finding.
There was a problem hiding this comment.
Actionable comments posted: 2
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: e058d6a8-16b4-4053-8c2b-2c85bdb0a281
📒 Files selected for processing (2)
scripts/pr_queue_health.pytests/test_pr_queue_health.py
|
Addressed the latest CodeRabbit edge-case comments in PR head What changed:
Extra parser sanity check: Validation:
|
|
Addressed the CodeRabbit whitespace/native-only follow-up on the updated PR branch. What changed:
Validation:
|
|
Correction/remote-branch verification: I fetched the exact TinyOps branch currently backing this PR and verified head The branch content handles the CodeRabbit edge cases: Validation on the fetched remote branch:
Note: my previous follow-up used the local patch worktree count before fetching the exact branch state; the fetched remote branch evidence above is the authoritative verification. |
Bounty #406
Summary:
live bounty #66/MRWK bounty #66while still acceptingissue #406,Refs #406, and/claim #406Evidence:
scripts/pr_queue_health.py --repo ramimbo/mergework --format jsonreported open MRWK bounty: useful bug reports and small fixes, round 5 #406/MRWK bounty: site UX and functional improvements #427 PRs asunknown_bounty_referencefor native bounty ids such as Prefill linked wallet on claim form #66 and Handle malformed bounty API JSON #73 when PR text included evidence likelive bounty #66 / issue #406Verification:
Summary by CodeRabbit
New Features
Improvements
Tests