A thorough first review on every pull request

Cyrus reviews every pull request as it opens, with line-level feedback you can commit in one click.

Add exponential backoff to email worker by mchen×
github.com/acme/api/pull/1291
acme / apiType / to search

Add exponential backoff to email worker #1291

Openmchen wants to merge 2 commits into main from mchen/email-backoff
Conversation3Commits2Checks4Files changed2
cyrusagent bot reviewed 4 minutes ago
⌄src/workers/email.ts+9 −2
4141 } catch (err) {
42- await sleep(5 * 60_000);
42+ const delay = Math.min(2 ** job.attempt * 1000, 120_000);
43+ await sleep(delay);
cyrusagentbot4 minutes ago
Resend sends a Retry-After header on 429s. Prefer it when present so we don’t retry before the window resets:
Suggested change
- const delay = Math.min(2 ** job.attempt * 1000, 120_000);
+ const delay = retryAfterMs(err) ?? Math.min(2 ** job.attempt * 1000, 120_000);
Commit suggestion
cyrusagent approved these changes just now

Reviews the moment a PR opens

No waiting for a teammate to free up. Cyrus starts as soon as the pull request opens, or when someone mentions @cyrusagent, so authors get feedback while the change is still fresh.

cyrusagent bot reviewed 1 minute after the PR opened
cyrusagentbotleft a review nowContributor···

Looks good overall. One real issue: the new webhook handler trusts event.amount from the request body instead of re-fetching the charge, so a forged payload could mark an order as paid. Details inline.

Line-level, with fixes you can commit

Comments land on the exact lines they are about. When the fix is clear, Cyrus attaches it as a suggested change the author can commit directly.

⌄src/workers/email.ts+9 −2
4141 } catch (err) {
42- await sleep(5 * 60_000);
42+ const delay = Math.min(2 ** job.attempt * 1000, 120_000);
43+ await sleep(delay);
cyrusagentbot4 minutes ago
Prefer Retry-After when the provider sends it:
Suggested change
- const delay = Math.min(2 ** job.attempt * 1000, 120_000);
+ const delay = retryAfterMs(err) ?? Math.min(2 ** job.attempt * 1000, 120_000);
Commit suggestion
Reply…

Requests changes when it matters

Cyrus focuses on correctness, security, and data loss, not style nits. When something is unsafe to merge, it requests changes and explains why.

cyrusagent requested changes 2 minutes ago
cyrusagentbotcommented 2 minutes agoContributor···

Blocking: DELETE /api/projects/:id no longer checks that the caller owns the project. Any signed-in user could delete another team’s project.

Restoring requireProjectOwner fixes it. I left a suggestion on line 64.

How Cyrus does it

  1. Install the GitHub app

    Choose the repositories Cyrus reviews. GitLab works too.

  2. A pull request opens

    Cyrus reviews automatically, or when someone mentions it in a comment.

  3. Cyrus reviews in context

    It reads the diff, the surrounding code, and the linked issue.

  4. Authors apply the feedback

    Suggested changes commit in one click, and Cyrus re-reviews on request.

More automations

Security patching Dependency advisories become tested pull requests.

E Engineering › ENG-482☆  ···‹  3 / 14  ›

Patch high-severity axios advisory

Dependabot alert #37 on acme/web: axios before 1.21.0 can forward credentials across cross-origin redirects. Severity: High.

ActivityUnsubscribe
DDependabot created the issue via GitHub14m ago
Security patching automation delegated to Cyrus14m ago
CyrusAgent2m agoCompleted
axios is a direct dependency of web and a transitive one through @acme/sdk.
Ran pnpm up axios@1.21.0 -r
Ran pnpm audit --prod0 vulnerabilities
Ran pnpm test312 passed
Opened acme/web#1294

Upgraded axios to 1.21.0 in web and @acme/sdk and refreshed the lockfile. The audit is clean and all 312 tests pass.

No code changes were needed. Ready for review in acme/web#1294.

Dev support Answers from your codebase, right in Slack.

←  →  ◷Search Acme?
# eng-support ⌄M24
MessagesCanvasFiles
Yesterday ⌄
P
Priya Nair2:14 PM
@Cyrus where do we set the session timeout for the dashboard?
2 repliesLast reply yesterday at 2:20 PM
S
Sam Okafor4:47 PM
Staging is back up after the database migration. Thanks for your patience, everyone.
If anything looks off, drop it in this channel.
Today ⌄
Connor9:12 AM
Reminder: on-call handoff moves to Thursdays starting next week.
S
Sam Okafor9:58 AM
@here web 2.41 is out. Release notes are in #product.
M
Maya Chen10:31 AM
@Cyrus customers say signup confirmation emails are arriving 10+ minutes late since yesterday. Can you take a look?
👀 1🙏 2
M3 repliesLast reply today at 10:38 AM
B I S 🔗 ≔ </>
Message #eng-support
+  Aa  ☺  @➤

Bug fixes Delegate a bug and get back a tested fix.

E Engineering › ENG-517☆  ···‹  3 / 14  ›

Discount codes apply twice when the cart is edited

Reported by two customers today. Apply a code, change a quantity, and the discount is subtracted a second time at checkout.

ActivityUnsubscribe
PPriya Nair delegated to Cyrus31m ago
CyrusAgent6m agoCompleted
Quantity changes re-run applyDiscount on an already-discounted total.
Added cart.test.ts › keeps one discount after editfails as reported
Edited src/cart/pricing.ts
Ran pnpm test cart48 passed
Opened acme/web#1302

Root cause: recalculate() applied the discount to the discounted subtotal instead of the original. The fix computes from line items every time. A regression test is included in acme/web#1302.

Approvals Routine fixes and security patches approved fast, by your code owners.

Bump axios to 1.21.0 by cyrusagent×
github.com/acme/web/pull/1294
acme / webType / to search

Bump axios to 1.21.0 #1294

Opencyrusagent wants to merge 1 commit into main from cyrus/eng-482-patch-axios
Conversation3Commits1Checks4Files changed2
cyrusagentbotcommented 2 minutes agoContributor···
Change riskLow 12
2 filesLockfile and package.json only312 tests pass
Risk of waitingHigh 81
High-severity advisoryCredentials exposed on redirectFix available

Pre-cleared by @mchen for dependency patches in web/. Requesting her approval.

M
mchen approved these changes Pre-cleared via Cyrusjust now
Changes approved
1 approving review by mchen
All checks have passed
4 successful checks
No conflicts with base branch
Merging can be performed automatically.
Merge pull request ▾You can also merge this with the command line.

Give every pull request a careful first review

Start a 7-day free trial on Pro or Team. Setup takes minutes.