spec(glue): settlement allocation follows the payment, not only its arrival - #35
Open
delchev wants to merge 1 commit into
Open
spec(glue): settlement allocation follows the payment, not only its arrival#35delchev wants to merge 1 commit into
delchev wants to merge 1 commit into
Conversation
…rrival Allocation is specified over the payment's whole life: it runs on the payment's create and on every later change, and each run allocates the unallocated balance rather than the pot again - so a correction settles for the amount the payment actually carries, a reduction gives the excess back newest-first, and a replayed change changes nothing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
settlementssection described the shape but left the when implicit, and every implementation read it as "once, on arrival". A payment is rarely final when it is typed in: one booked for the wrong amount is corrected the next day, one entered from a bank statement is completed once the counter-party is identified. The allocation - and with it every invoice's settled figure - was left describing an amount the payment no longer carried.Specifies allocation over the payment's whole life:
potless what is already allocated through the junction) rather than the pot again, so a re-delivered or replayed change leaves the allocation unchanged;paidroll-up follows them down.Companion proposal: IntentFile/intent-specification#44. Implementation: eclipse-dirigible/dirigible#6818.
npx vitepress build docspasses.🤖 Generated with Claude Code