Skip to content

Fix error naming conventions - #627

Open
d3v-active wants to merge 3 commits into
BCPathway:mainfrom
d3v-active:fix-error-naming-conventions
Open

Fix error naming conventions#627
d3v-active wants to merge 3 commits into
BCPathway:mainfrom
d3v-active:fix-error-naming-conventions

Conversation

@d3v-active

Copy link
Copy Markdown

Closes #502

This PR reviews and standardizes the error naming conventions and documentation across all smart contracts in the repository to ensure they follow NatSpec (Rust documentation) standards.

Changes Made

While the error enums were already correctly named using standard Rust/Soroban conventions (e.g., SplitError, TokenError, etc.), many of the variants lacked descriptive documentation, making it harder for developers and users to understand why an operation failed.

The following contracts were updated to include clear and accurate docstrings for all custom error variants:

  • split/src/lib.rs: Added complete documentation for SplitError.
  • token/src/lib.rs: Added complete documentation for TokenError.
  • vesting/src/lib.rs: Added complete documentation for VestingError.
  • wrapper/src/lib.rs: Added complete documentation for all previously undocumented variants of WrapperError.

Acceptance Criteria Met

  • Documentation is clear and accurate.
  • Linter/Formatter passes with 0 warnings (cargo fmt and cargo clippy were run to verify).
  • Follows standard developer specification comments (equivalent to NatSpec in Solidity).

Impact

No business logic was changed. These are purely documentation enhancements to improve the developer experience and maintain code quality and consistency across the project.

@drips-wave

drips-wave Bot commented Jul 29, 2026

Copy link
Copy Markdown

@d3v-active Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Docs & Polish] Review and standardize error naming conventions

1 participant