Repository navigation
feat(portal): apply the launch discount to orders with hosting - #622
Conversation
@codex review for launch discount: one place per client under an advisory lock, discounted one-time price stored on the order, refusal when the last place went before ordering, invoice and Stripe line text |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 97f8b61daf
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
✅MegaLinter analysis: Success
See detailed reports in MegaLinter artifacts Your project could benefit from a custom flavor, which would allow you to run only the linters you need, and thus improve runtime performances. (Skip this info by defining
|
Code coverage overviewLanguages: Go Go / code-coverage/go
Line coverage data for the main branch is not yet available. View coverage of the 10 most covered files.
ℹ️ Calculations represent line coverage. Results may change as calculations are updated. Updated |
Codex review on #622: readLaunchOffer evaluated the order gate after showRequests had read the private request, proposal and acceptance records. The caller already evaluates that gate first, so the helper no longer evaluates any flag. Also fixes gocritic's offBy1 and revive's unused parameter in the launch tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codex review for Re-review after the findings on the previous head were fixed (see the replies on each thread). |
|
Codex Review: Didn't find any major issues. Another round soon, please! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Codex review on #622: readLaunchOffer evaluated the order gate after showRequests had read the private request, proposal and acceptance records. The caller already evaluates that gate first, so the helper no longer evaluates any flag. Also fixes gocritic's offBy1 and revive's unused parameter in the launch tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
3b46f0c to
dd0f46a
Compare
|
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Codex review on #622: readLaunchOffer evaluated the order gate after showRequests had read the private request, proposal and acceptance records. The caller already evaluates that gate first, so the helper no longer evaluates any flag. Also fixes gocritic's offBy1 and revive's unused parameter in the launch tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
dd0f46a to
a592c55
Compare
|
Codex Review: Didn't find any major issues. 🚀 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
The maintainer's launch offer (offerings.json launchDiscount): 25% off the one-time price for the first 50 customers who order with hosting. - An order with a one-time and a monthly price takes the client's launch place, if one is open, in the transaction that inserts it, under an advisory lock (portal_launch_places, migration v24). One place per client; a taken place is never reused. - The order stores the discounted one-time price, so invoices, card payments, funding and withdrawals use it unchanged. Hosting keeps its full price. - The shared proposal, the order summary and the receipt show the discount as its own line. An order whose place went after the client saw the price is refused, and the receipt shows the new price. - Numina and Stripe lines carry the discounted price and name the full price and the discount; the confirmation email and the operator's page show it too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codex review on #622: readLaunchOffer evaluated the order gate after showRequests had read the private request, proposal and acceptance records. The caller already evaluates that gate first, so the helper no longer evaluates any flag. Also fixes gocritic's offBy1 and revive's unused parameter in the launch tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
a592c55 to
e357d88
Compare
|
Codex Review: Didn't find any major issues. Nice work! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |

The maintainer's launch offer: 25% off the one-time price for the first 50 customers who order with hosting. Hosting keeps its full price. This PR makes the portal apply it, behind the existing order gates.
Stacked on #625 (new prices and the
launchDiscountblock inofferings.json). Review only this PR's commits. This PR makesofferingCatalogue.LaunchDiscounta pointer, so tests can switch the offer off. It also validates the block at load and points #625's drift assertion at the published value. CI failsTestProposalGeneratedVersionSavesWithoutTypinguntil #625 updates that test to its new app prices.Rules (confirmed by the parent session)
percentof its one-time price rounded to whole kroner.portal_launch_places, migration v24). The 50th order gets the discount and the 51st doesn't.… — normalpris 6000 DKK, lanceringsrabat 25 % −1500 DKK. A unit price that already includes the discount is valid on a Danish invoice, so the maintainer needs no Stripe coupon or negative Numina line. The confirmation email names it, and the operator's page shows the place number.appliesToother thansetup, orrequiresHostingother than true.Tests
TestLaunch*:Mutation checks are load-bearing: removing the lock, the limit, the per-customer check or the changed-price refusal each fails its test.
The other tests run with the offer off (
initinlaunch_test.go), so their prices stay as written. The full Go suite passes: all four cohorts,contactintegrationandcontacttrialintegration. golangci-lint, vet, gofmt, jscpd and cspell are clean.Part of #21
🤖 Generated with Claude Code