From 20f65205e5a81396746436c34f0ee392bbfda558 Mon Sep 17 00:00:00 2001 From: Ramkumar SG Date: Mon, 19 Apr 2021 13:50:36 -0700 Subject: [PATCH 1/3] tickets.md - typo in account sequence numbers Also, the images img/ticket-creation.svg & img/ticket-usage.svg have to be updated with the right account sequence numbers --- content/concepts/payment-system-basics/accounts/tickets.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/content/concepts/payment-system-basics/accounts/tickets.md b/content/concepts/payment-system-basics/accounts/tickets.md index a9d178d019..e43098bced 100644 --- a/content/concepts/payment-system-basics/accounts/tickets.md +++ b/content/concepts/payment-system-basics/accounts/tickets.md @@ -30,7 +30,7 @@ Tickets provide a solution to all of these problems by setting aside sequence nu A Ticket is a record that a sequence number has been set aside to be used later. An account first sends a [TicketCreate transaction][] to set aside one or more sequence numbers as Tickets; this puts a record in the [ledger's state data](ledgers.html), in the form of a [Ticket object][], for each sequence number reserved. -Tickets are numbered using the sequence numbers that were set aside to create them. For example, if your account's current sequence number is 101 and you create 3 Tickets, those Tickets have Ticket Sequence numbers 101, 102, and 103. Doing so increases your account's sequence number to 104. +Tickets are numbered using the sequence numbers that were set aside to create them. For example, if your account's current sequence number is 101 and you create 3 Tickets, those Tickets have Ticket Sequence numbers 102, 103, and 104. Doing so increases your account's sequence number to 105. {{ include_svg("img/ticket-creation.svg", "Diagram: Creating three Tickets") }} @@ -38,7 +38,7 @@ Later, you can send a transaction using a specific Ticket instead of a sequence {{ include_svg("img/ticket-usage.svg", "Diagram: Using Ticket 102.") }} -Continuing the above example, you can send a transaction using sequence number 104 or any of the three Tickets you created. If you send a transaction using Ticket 102, doing so deletes Ticket 102 from the ledger. Your next transaction after that can use sequence number 104, Ticket 101, or Ticket 103. +Continuing the above example, you can send a transaction using sequence number 105 or any of the three Tickets you created. If you send a transaction using Ticket 102, doing so deletes Ticket 102 from the ledger. Your next transaction after that can use sequence number 105, Ticket 103, or Ticket 104. **Caution:** Each Ticket counts as a separate item for the [owner reserve](reserves.html), so you must set aside 5 XRP for each Ticket. (The XRP becomes available again after you use the Ticket.) This cost can add up quickly if you create a large number of Tickets at once. From 75e0d3bf332e0f18235097587aa21c8574ca07cf Mon Sep 17 00:00:00 2001 From: Ramkumar SG Date: Mon, 19 Apr 2021 14:18:56 -0700 Subject: [PATCH 2/3] Update Flow diagrams --- content/_img-sources/ticket-creation.uxf | 8 ++++---- content/_img-sources/ticket-usage.uxf | 18 +++++++++--------- .../payment-system-basics/accounts/tickets.md | 4 ++-- 3 files changed, 15 insertions(+), 15 deletions(-) diff --git a/content/_img-sources/ticket-creation.uxf b/content/_img-sources/ticket-creation.uxf index bd0a719226..51f303bd1b 100644 --- a/content/_img-sources/ticket-creation.uxf +++ b/content/_img-sources/ticket-creation.uxf @@ -40,7 +40,7 @@ lt=. Account -- ID: rf1Bi... -*Sequence: 104* +*Sequence: 105* @@ -54,7 +54,7 @@ ID: rf1Bi... Ticket -- Account: rf1Bi... -Sequence: 101 +Sequence: 102 @@ -68,7 +68,7 @@ Sequence: 101 Ticket -- Account: rf1Bi... -Sequence: 102 +Sequence: 103 @@ -82,7 +82,7 @@ Sequence: 102 Ticket -- Account: rf1Bi... -Sequence: 103 +Sequence: 104 diff --git a/content/_img-sources/ticket-usage.uxf b/content/_img-sources/ticket-usage.uxf index f8cddf59d4..ab827f8058 100644 --- a/content/_img-sources/ticket-usage.uxf +++ b/content/_img-sources/ticket-usage.uxf @@ -24,7 +24,7 @@ lt=. Account -- ID: rf1Bi... -Sequence: 104 +Sequence: 105 @@ -38,7 +38,7 @@ Sequence: 104 Ticket -- Account: rf1Bi... -Sequence: 101 +Sequence: 102 @@ -52,7 +52,7 @@ Sequence: 101 Ticket -- Account: rf1Bi... -Sequence: 102 +Sequence: 103 @@ -66,7 +66,7 @@ Sequence: 102 Ticket -- Account: rf1Bi... -Sequence: 103 +Sequence: 104 @@ -82,7 +82,7 @@ transaction) -- Account: rf1Bi... Sequence: 0 -TicketSequence: 102 +TicketSequence: 103 ... @@ -121,7 +121,7 @@ used Account -- ID: rf1Bi... -Sequence: 104 +Sequence: 105 @@ -157,7 +157,7 @@ Sequence: 104 Ticket -- Account: rf1Bi... -Sequence: 101 +Sequence: 102 @@ -171,7 +171,7 @@ Sequence: 101 Ticket -- Account: rf1Bi... -Sequence: 103 +Sequence: 104 @@ -195,7 +195,7 @@ Sequence: 103 90 50 - Ticket 102 deleted + Ticket 103 deleted style=wordwrap diff --git a/content/concepts/payment-system-basics/accounts/tickets.md b/content/concepts/payment-system-basics/accounts/tickets.md index e43098bced..10fc4133c3 100644 --- a/content/concepts/payment-system-basics/accounts/tickets.md +++ b/content/concepts/payment-system-basics/accounts/tickets.md @@ -36,9 +36,9 @@ Tickets are numbered using the sequence numbers that were set aside to create th Later, you can send a transaction using a specific Ticket instead of a sequence number; doing so removes the corresponding Ticket from the ledger's state data and does not change your account's normal sequence number. You can also still send transactions using normal sequence numbers without using Tickets. You can use any of your available Tickets in any order at any time, but each Ticket can only be used once. -{{ include_svg("img/ticket-usage.svg", "Diagram: Using Ticket 102.") }} +{{ include_svg("img/ticket-usage.svg", "Diagram: Using Ticket 103.") }} -Continuing the above example, you can send a transaction using sequence number 105 or any of the three Tickets you created. If you send a transaction using Ticket 102, doing so deletes Ticket 102 from the ledger. Your next transaction after that can use sequence number 105, Ticket 103, or Ticket 104. +Continuing the above example, you can send a transaction using sequence number 105 or any of the three Tickets you created. If you send a transaction using Ticket 103, doing so deletes Ticket 103 from the ledger. Your next transaction after that can use sequence number 105, Ticket 102, or Ticket 104. **Caution:** Each Ticket counts as a separate item for the [owner reserve](reserves.html), so you must set aside 5 XRP for each Ticket. (The XRP becomes available again after you use the Ticket.) This cost can add up quickly if you create a large number of Tickets at once. From 0093cb28881b826e64d517d8bcc172c767e17182 Mon Sep 17 00:00:00 2001 From: mDuo13 Date: Wed, 21 Apr 2021 12:06:50 -0700 Subject: [PATCH 3/3] TicketCreate: correct sequence number off-by-one in more places --- .../transaction-types/ticketcreate.md | 2 +- img/ticket-creation.svg | 72 ++++++------ img/ticket-usage.svg | 104 +++++++++--------- 3 files changed, 89 insertions(+), 89 deletions(-) diff --git a/content/references/rippled-api/transaction-formats/transaction-types/ticketcreate.md b/content/references/rippled-api/transaction-formats/transaction-types/ticketcreate.md index d7472dcd43..0226fb9046 100644 --- a/content/references/rippled-api/transaction-formats/transaction-types/ticketcreate.md +++ b/content/references/rippled-api/transaction-formats/transaction-types/ticketcreate.md @@ -38,7 +38,7 @@ A TicketCreate transaction sets aside one or more [sequence numbers][Sequence Nu If the transaction cannot create _all_ of the requested Tickets (either due to the 250-Ticket limit or the [owner reserve](reserves.html)), it fails and creates no Tickets. To look up how many Tickets an account currently owns, use the [account_info method][] and check the `account_data.TicketCount` field. -**Tip:** This transaction increases the sending account's [sequence number][Sequence Number] by the number of tickets created (`TicketCount`). This is the only transaction that increases an account's sequence number by more than 1. +**Tip:** This transaction increases the sending account's [sequence number][Sequence Number] by 1 _plus_ the number of tickets created (`TicketCount`). This is the only transaction that increases an account's sequence number by more than 1. ## Error Cases diff --git a/img/ticket-creation.svg b/img/ticket-creation.svg index cf65aa6cce..55f6f38ca0 100644 --- a/img/ticket-creation.svg +++ b/img/ticket-creation.svg @@ -49,15 +49,15 @@ />......createsAccountID: rf1Bi...Sequence: 101Ledger State Data (Before)TicketAccount: rf1Bi...Sequence: 103Sequence: 104TicketAccount: rf1Bi...Sequence: 102Sequence: 103TicketAccount: rf1Bi...Sequence: 101Sequence: 102AccountID: rf1Bi...Sequence: 104Sequence: 105Ledger State Data (After)TicketCreatetransactionAccount: rf1Bi...TicketCount: 3Sequence: 101updates......Ticket 102Ticket 103deletedTicketAccount: rf1Bi...Sequence: 103Sequence: 104TicketAccount: rf1Bi...Sequence: 101Sequence: 102Doesn't changeAccountID: rf1Bi...Sequence: 104Sequence: 105Ledger State Data (Before)(Any type oftransaction)Account: rf1Bi...Sequence: 0TicketSequence: 102TicketSequence: 103...TicketAccount: rf1Bi...Sequence: 103Sequence: 104TicketAccount: rf1Bi...Sequence: 102Sequence: 103TicketAccount: rf1Bi...Sequence: 101Sequence: 102AccountID: rf1Bi...Sequence: 104Sequence: 105Ledger State Data (After)used