alpha
Login
or
Join now
lgtm.shop
/
commerce
Star
5
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Pilot atproto-native commerce backend
Star
5
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Overview
Issues
Pulls
Pipelines
commerce
/
crates
/
worker
/
src
/
at
main
5 files
Nate Moore
fix(checkout): make real Stripe checkout succeed (was a bare 400 for every order)
6d ago
a367e244
handlers.rs
fix(worker): receipt buyer_did from space skey, not order author_did Orders are store-authored (SPEC 8), so author_did is the store DID; load_order sourced buyer_did from it, making receipts record the store as buyer. Source it from the space skey.
2 weeks ago
lib.rs
fix(boot): run apalis PostgresStorage::setup after migrations so job enqueue works; default-run=lgtm-backend Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 month ago
main.rs
M10 T34: worker apalis Postgres storage, Job enum, enqueue + monitor builder Job enum (serde tag="kind"), PostgresStorage with "worker::Job" namespace, enqueue() pushes a job row, build_monitor() registers one worker dispatching ProcessPaidOrder/AttestClaim/Reconcile. Tests: serde round-trip + live enqueue against apalis.jobs (apalis storage setup works under #[sqlx::test], no #[ignore]). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 month ago
production.rs
fix(checkout): make real Stripe checkout succeed (was a bare 400 for every order) With fake-payments off, every POST /api/checkout returned an empty-body 400. The real Stripe path could never succeed: place_order sent empty success_url/ cancel_url and DbVariantLookup left product_uri (used as the Stripe line-item name) empty. Stripe rejects both, and the handler swallowed the error with a bare `Err(_) => 400`, making it undebuggable from the storefront. - Thread configurable redirect URLs through place_order. New optional env vars LGTM_CHECKOUT_SUCCESS_URL / LGTM_CHECKOUT_CANCEL_URL, defaulting to {public_url}/checkout/success?session_id={CHECKOUT_SESSION_ID} and {public_url}/cart. - DbVariantLookup joins product for the real at_uri + title; carry a display name through VariantInfo -> DraftLine -> OrderItem to the Stripe line item (fallback title -> SKU -> "Item"). Name is a checkout-time snapshot, not persisted in P1. - Map checkout errors: validation/currency/not-found -> descriptive 400; missing key / provider rejection -> logged in full + generic 502, never a bare empty 400. Tests: place_order fake now asserts non-empty URLs + names are forwarded; DbVariantLookup join covered (title + SKU fallback); config default/override.
6 days ago
reconcile.rs
M10 T37: reconcile (local vs provider status) + apalis dead-letter surfacing reconcile_with diffs each fulfillment row's local status against the provider's status (via the ProviderStatus port) and returns the divergences for the admin (SPEC §18); unreachable providers are skipped, not false-flagged. The public reconcile() uses a no-op adapter until M11 wires the Registry. dead_letters() queries apalis.jobs for Failed jobs with their last_error + attempt count. Tested with fakes / seeded rows: one divergent + one agreeing order yields exactly one mismatch; a seeded Failed apalis job is surfaced. The dead-letter test uses bare #[sqlx::test] (apalis owns its tables; mixing the two migrators in one DB clashes on versioning). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 month ago