Skip to content

fleet(queue): default max_attempts to 1000 on every task-creation path (#8973) - #9903

Merged
dezren39 merged 1 commit into
mainfrom
queue/15155-8973-max-attempts-default
Nov 14, 2026
Merged

dezren39 merged 1 commit into
mainfrom
queue/15155-8973-max-attempts-default

Conversation

@dezren39

@dezren39 dezren39 commented Nov 14, 2026 •

Copy link
Copy Markdown
Member

Closes #8973. Task 15155 (queue repo-health-code-pilot, lane any-c).

What

Drew order 2026-11-12 (#8973): new tasks default to max_attempts = 1000 so they stop dying at tiny retry ceilings. The validator-ceiling half landed in #9609 (PR #9621); the creation defaults still produced small values. This PR raises every task-creation default in this repo to 1000:

Explicit per-packet values are unchanged. The creation_outbox retry cap (8) is a separate GitHub-delivery domain and is deliberately untouched.

Verification (oracle: a task created without an explicit max_attempts reads back 1000)

  • New test enqueue_dry_run_defaults_max_attempts_1000_per_8973: a valid packet omitting max_attempts in both copies enqueues (dry-run readback of the exact row shape the insert consumes) with max_attempts = 1000.
  • New source-oracle task_creation_defaults_max_attempts_1000_per_8973: schema default + insert fallback carry 1000, no stale tasks schema default of 4.
  • validate packet test updated: both copies missing now defaults to 1000.
  • cargo test -p fleet-queue --features queue-broker,client: 310 + 1 passed, 0 failed.
  • Dispatch: bun test test/packet.test.ts 4 passed (expectations updated to 1000). Full dispatch suite: the only failures were GitHubClient tests hitting their 5s timeout under parallel load; that file passes standalone (12/12) in this worktree and on pristine main - pre-existing flakiness, untouched by this change.
  • check_coverage.py compiles (py_compile).

Note: the live broker picks this up on its next deploy from main; until then the deployed binary still defaults to 4 on the packet-less path, while packets that carry 1000 explicitly (the current producer norm) already validate and claim clean post-#9609.


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

#8973)

Drew order 2026-11-12 (#8973): new tasks inherit max_attempts=1000 so they stop dying at tiny retry ceilings. The validator ceiling half landed in #9609 (PR #9621); this raises the creation defaults that still produced small values:

- fleet-queue: one TASK_DEFAULT_MAX_ATTEMPTS=1000 constant in validate.rs, used by task_from_packet (broker/enqueue packet path) and the turso enqueue insert fallback; tasks schema DEFAULT 4 -> 1000; the design-default warning now expects 1000 for every kind instead of 4/6.
- pm-stack/dispatch producer: packet max_attempts 2/3 -> 1000.
- queue-reconcile coverage producer: max_attempts 6 -> 1000.

Explicit per-packet values are unchanged, and the creation_outbox retry cap (8) is a separate GitHub-delivery domain, deliberately untouched.

Tests (oracle: a task created without an explicit max_attempts reads back 1000): validate packet_max_attempts test updated to the new default; new turso_queue source-oracle task_creation_defaults_max_attempts_1000_per_8973; dispatch packet tests updated. cargo test -p fleet-queue --features queue-broker,client: 309+1 passed. bun packet.test.ts: 4 passed.
@dezren39
dezren39 requested a review from a team as a code owner November 14, 2026 10:55
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-14T10:57:27.364762Z
We couldn’t complete this review. Comment @codex review to try again.
d67e7bf Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@coderabbitai

coderabbitai Bot commented Nov 14, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 28 seconds.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 4630c06f-ecc1-406d-9b4e-ad8aa958b451
Commits

Reviewing files that changed from the base of the PR and between 7151803 and d67e7bf.

Files selected for processing: 5

  • pkgs/fleet/crates/fleet-queue/src/turso_queue.rs
  • pkgs/fleet/crates/fleet-queue/src/validate.rs
  • pm-stack/dispatch/src/packet.ts
  • pm-stack/dispatch/test/packet.test.ts
  • scripts/fleet/queue-reconcile/check_coverage.py
  • 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

@dezren39

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@dezren39

Copy link
Copy Markdown
Member Author

🤖 Agent note · merge_ready (task 15155, lane any-c)

Codex findings disposition (2026-10-29 gate): the Codex code review on this PR did not complete — the connector reported "We couldn't complete this review" on the opening pass and "You have reached your Codex usage limits for code reviews" immediately after; a @codex review retry (comment 6876238058) produced no new review after several minutes. Zero Codex findings exist on this PR to disposition — the failure is a reviewer-quota outage, not a finding. Proceeding to merge on the locally verified evidence in the PR body (cargo test -p fleet-queue --features queue-broker,client: 310 + 1 passed; dispatch packet tests 4 passed) per the standing merge authority (PRs do not wait; not merged = not done). If Codex later posts findings on the merged PR, they will be handled as a follow-up fix.

Merging now.

@dezren39
dezren39 merged commit c72f522 into main Nov 14, 2026
1 check passed
@dezren39
dezren39 deleted the queue/15155-8973-max-attempts-default branch November 14, 2026 11:00
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits. You can see your limits in the Codex usage dashboard.

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.

queue: raise default max_attempts for new tasks to 1000 (Drew order 2026-11-12)

1 participant