-
Notifications
You must be signed in to change notification settings - Fork 12.4k
docs: document Errors utility library in utils README #6186
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
base: typo-fixes
Are you sure you want to change the base?
docs: document Errors utility library in utils README #6186
Conversation
|
WalkthroughThe change updates documentation in the utilities README file to include a new library reference. Specifically, it adds an entry for the Errors utility library to both the utilities list and the generated index of libraries. The modifications consist of documentation-only updates with no changes to functional code or exported entity declarations. The alterations involve adding the library reference and adjusting surrounding formatting for consistency with existing documentation structure. Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
Actionable comments posted: 2
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
contracts/utils/README.adoc(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (9)
- GitHub Check: tests
- GitHub Check: slither
- GitHub Check: tests-upgradeable
- GitHub Check: tests-foundry
- GitHub Check: coverage
- GitHub Check: Redirect rules - solidity-contracts
- GitHub Check: halmos
- GitHub Check: Header rules - solidity-contracts
- GitHub Check: Pages changed - solidity-contracts
| * {Multicall}: Abstract contract with a utility to allow batching together multiple calls in a single transaction. Useful for allowing EOAs to perform multiple operations at once. | ||
| * {Packing}: A library for packing and unpacking multiple values into bytes32. | ||
| * {Panic}: A library to revert with https://docs.soliditylang.org/en/v0.8.20/control-structures.html#panic-via-assert-and-error-via-require[Solidity panic codes]. | ||
| * {Errors}: Collection of common custom errors used in multiple contracts. |
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.
Alphabetical ordering issue in utilities list.
The Errors library is inserted between Panic and RelayedCall, but alphabetically it should be positioned between Create2 and InteroperableAddress (letter 'E' comes before 'I' and 'P'). Move the entry to maintain alphabetical consistency with the rest of the utilities list.
- * {Panic}: A library to revert with https://docs.soliditylang.org/en/v0.8.20/control-structures.html#panic-via-assert-and-error-via-require[Solidity panic codes].
+ * {Panic}: A library to revert with https://docs.soliditylang.org/en/v0.8.20/control-structures.html#panic-via-assert-and-error-via-require[Solidity panic codes].
+ * {Errors}: Collection of common custom errors used in multiple contracts.
- * {Errors}: Collection of common custom errors used in multiple contracts.
* {RelayedCall}: A library for performing calls that use minimal and predictable relayers to hide the sender.Actually, this needs to be placed earlier in the list. Apply this diff instead:
* {Create2}: Wrapper around the https://blog.openzeppelin.com/getting-the-most-out-of-create2/[`CREATE2` EVM opcode] for safe use without having to deal with low-level assembly.
+ * {Errors}: Collection of common custom errors used in multiple contracts.
* {InteroperableAddress}: Library for formatting and parsing ERC-7930 interoperable addresses.Committable suggestion skipped: line range outside the PR's diff.
🤖 Prompt for AI Agents
In contracts/utils/README.adoc around line 42, the "Errors" entry is out of
alphabetical order (currently placed between Panic and RelayedCall); remove that
entry from its current spot and reinsert it earlier in the utilities list so it
appears between "Create2" and "InteroperableAddress" to maintain alphabetical
ordering.
| {{Errors}} | ||
|
|
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.
Alphabetical ordering issue in Libraries section index.
The {{Errors}} entry is positioned between {{Panic}} and {{RelayedCall}}, which breaks alphabetical ordering. Move it to maintain consistency with the structured list above and alphabetical ordering within the Libraries section (between {{Create2}} and {{InteroperableAddress}}).
{{Create2}}
+ {{Errors}}
+
{{InteroperableAddress}}And remove it from its current location:
{{Panic}}
- {{Errors}}
-
{{RelayedCall}}Committable suggestion skipped: line range outside the PR's diff.
🤖 Prompt for AI Agents
In contracts/utils/README.adoc around lines 147-148, the {{Errors}} index entry
is misplaced between {{Panic}} and {{RelayedCall}}, breaking the Libraries
section alphabetical order; remove the {{Errors}} occurrence at its current
location and reinsert a single {{Errors}} entry in the Libraries index between
{{Create2}} and {{InteroperableAddress}} so the list remains alphabetically
ordered and consistent with the structured list above.
Add the Errors library to the utils README so that common custom error utilities are visible in the public API docs. This keeps the documentation in sync with the existing Errors.sol module and makes it easier for users to discover and reuse shared error types.