Committing the balance, risking the ledger
I wrapped a balance update and an audit log write in one transaction. Then a log insert failed and rolled back a reward the user should have had.
Page 5 of 6.
62 posts, newest first
I wrapped a balance update and an audit log write in one transaction. Then a log insert failed and rolled back a reward the user should have had.
One endpoint, hit three or four times during onboarding, sometimes before the user record finished writing. It still had to pay the bonus exactly once.
A challenge creator got a bonus for winning. They also got it for winning again, on the same challenge, because a retry doesn't know it's a retry.
A student is enrolled in six classes. On a given day they open one, maybe two. We were generating all six anyway, and paying for five nobody would ever see.
A ten-question quiz request sometimes came back with eight questions, sometimes twelve, sometimes ten where two didn't have a correct answer among the options.
"Solve $3x + 7 = 22$" and "a shirt costs $20" use the same character for two different jobs. The renderer couldn't tell them apart. Neither could my regex.
A student asked for more practice questions on the same topic four times in a row. The third batch had a question nearly identical to one from the first.
Across a batch of auto-generated quizzes, the correct answer kept landing in the same slot. Prompting the model to vary it helped. It didn't fix it.
A page crashed reading state that should have existed. A Redux slice was registered in one bootstrap path, and a second valid path never went through it.
A user tapped accept twice and hit a flow expecting a fresh acceptance. The second call returned success silently, and success was the cue to proceed.
Users were told to check their internet connection. It was fine. A switch built for 3 error codes was still running after the real list grew to 6.
A quiz report showed every answer as wrong, and a carousel on the same page crashed. Same cause: a call site that skipped a step every other one took.