-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ledger method: update for 1.12.0 #2248
Conversation
Link check report. 554061 links checked. Preview: https://XRPLF.github.io/xrpl-dev-portal/pr-preview/ledger_remove_deprecated_fields/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @mDuo13 , thanks for this PR. I have asked a few clarifying questions.
I couldn't observe any changes in the behavior of close_flags
. Although the description of the PR mentions it, I didn't see any changes. Did I miss something?
@@ -191,27 +107,28 @@ The response follows the [standard format][], with a successful result containin | |||
|
|||
| `Field` | Type | Description | | |||
|:-------------------------------|:--------|:----------------------------------| | |||
| `ledger` | Object | The complete header data of this ledger. | | |||
| `ledger.account_hash` | String | Hash of all account state information in this ledger, as hex | | |||
| `ledger.accountState` | Array | (Omitted unless requested) All the [account-state information](ledger-data-formats.html) in this ledger. | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was of the understanding that we mark a field as [deprecated]
and gracefully remove it from the responses. Have we informed the community sufficiently in advance?
My apologies if this was communicated before, I'm not aware of this development.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the communication. The code will still work without changes, but this updates the docs to communicate the deprecation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh okay :+1
| `queue_data` | Array | _(Omitted unless requested with the `queue` parameter)_ Array of objects describing queued transactions, in the same order as the queue. If the request specified `expand` as true, members contain full representations of the transactions, in either JSON or binary depending on whether the request specified `binary` as true. Added by the [FeeEscalation amendment][]. [New in: rippled 0.70.0][] | | ||
| `queue_data` | Array | _(Omitted unless requested with the `queue` parameter)_ Array of objects describing queued transactions, in the same order as the queue. If the request specified `expand` as true, members contain full representations of the transactions, in either JSON or binary depending on whether the request specified `binary` as true. | | ||
|
||
The `ledger.accountState` field (omitted unless requested with `"full": true` or `"accounts": true`) is deprecated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The `ledger.accountState` field (omitted unless requested with `"full": true` or `"accounts": true`) is deprecated. | |
The `ledger.accountState` field is deprecated. |
^^ I feel this would convey the meaning better, since full
and accounts
have been deprecated themselves
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I felt the note was needed because otherwise it might be confusing to be told that a field you don't see is deprecated—people might wonder if it has been removed already. This makes it clear when you should expect to see the field even though it is deprecated.
@@ -238,7 +155,7 @@ If the request specified `"owner_funds": true` and expanded transactions, the re | |||
* Any of the [universal error types][]. | |||
* `invalidParams` - One or more fields are specified incorrectly, or one or more required fields are missing. | |||
* `lgrNotFound` - The ledger specified by the `ledger_hash` or `ledger_index` does not exist, or it does exist but the server does not have it. | |||
* `noPermission` - If you specified `full` or `accounts` as true, but are not connected to the server as an admin (usually, admin requires connecting on a local port). | |||
* `noPermission` - If you specified `full` or `accounts` as true, but are not connected to the server as an admin (usually, admin requires connecting on localhost). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't full
and accounts
deprecated? Is it possible to get noPermission
error even without these fields?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's true, but deprecated does not mean removed, so it's still a real error that can occur.
@@ -3144,6 +3144,7 @@ pages: | |||
- en | |||
|
|||
- md: "@i18n/ja/references/http-websocket-apis/public-api-methods/ledger-methods/ledger.md" | |||
outdated_translation: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you explain what this addition means?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It displays a warning on the Japanese version of the page telling users that the translated version of the page isn't up-to-date with the English version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
very cool!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this looks good to me 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Fix #2158
full
andaccounts
parameters and the correspondingaccountState
response field as deprecated.close_flags
being omitted from the JSON representation of a ledger header.