-
Notifications
You must be signed in to change notification settings - Fork 147
docs: enhance TokenType enum docstring #1394
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
docs: enhance TokenType enum docstring #1394
Conversation
- Add comprehensive docstring explaining inclusive vs exclusive fee assessment - Clarify when each method should be used and their payment implications - Update changelog entry Fixes #1391 Signed-off-by: cheese-cakee <[email protected]>
- Add comprehensive docstring explaining fungible vs non-fungible tokens - Provide use cases and examples for each token type - Update changelog entry Fixes #1392 Signed-off-by: cheese-cakee <[email protected]>
|
Warning Rate limit exceeded@cheese-cakee has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 22 minutes and 52 seconds before requesting another review. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe TokenType enum class documentation was expanded with a comprehensive docstring explaining fungible versus non-fungible token types, use cases, and implementation details. A corresponding changelog entry was added to document this documentation enhancement. Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. 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: 1
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (2)
CHANGELOG.mdsrc/hiero_sdk_python/tokens/token_type.py
🧰 Additional context used
🪛 Ruff (0.14.10)
src/hiero_sdk_python/tokens/token_type.py
15-15: Docstring contains ambiguous – (EN DASH). Did you mean - (HYPHEN-MINUS)?
(RUF002)
19-19: Docstring contains ambiguous – (EN DASH). Did you mean - (HYPHEN-MINUS)?
(RUF002)
⏰ 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). (1)
- GitHub Check: Codacy Static Code Analysis
🔇 Additional comments (1)
CHANGELOG.md (1)
10-10: Changelog entry is clear and appropriately placed.The entry accurately describes the documentation enhancement and includes the linked issue reference. Formatting is consistent with surrounding entries.
Fix RUF002 linting error by replacing – with - in docstring to comply with code style guidelines. Signed-off-by: cheese-cakee <[email protected]>
Fix RUF002 linting error by replacing – with - in docstring to comply with code style guidelines. Signed-off-by: cheese-cakee <[email protected]>
| """ | ||
| Token type for Hedera tokens: | ||
| • FUNGIBLE_COMMON - Interchangeable tokens where each unit is equal. |
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.
indentation for both must match please
| unique assets. Each token has its own metadata and | ||
| identity. | ||
| This enum determines whether a token represents a divisible, interchangeable |
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.
similarly,the explanation goes near the top
| """ | ||
| Token type for Hedera tokens: | ||
| • FUNGIBLE_COMMON - Interchangeable tokens where each unit is equal. |
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.
these are grouped under attributes please
|
Hi, this is MergeConflictBot. Please resolve these conflicts locally and push the changes. To assist you, please read: Thank you for contributing! |
…ples - Add comprehensive Google-style docstring with Attributes, Examples, Args, Returns sections - Include practical example usage for better developer understanding - Maintain existing functionality while improving documentation quality Addresses maintainer feedback for better docstring format Signed-off-by: cheese-cakee <[email protected]>
- Add comprehensive Google-style docstring with Attributes, Examples, Args, Returns sections - Include practical example usage for better developer understanding - Maintain existing functionality while improving documentation quality Addresses maintainer feedback for better docstring format Signed-off-by: cheese-cakee <[email protected]>
- Both PRs are up to date with latest changes - No actual merge conflicts detected - Documentation improvements implemented as requested by maintainer
Signed-off-by: cheese-cakee <[email protected]>
…ocstring improvements - Add changelog entries for PR #1393 and #1394 - Document enhanced docstrings with Google-style format and examples - Reflects proper contributor acknowledgments Prepares changelog for proper documentation of recent enhancements Signed-off-by: cheese-cakee <[email protected]>
- Force GitHub to update PR status with latest changes
| >>> print(f"Token type: {token_type}") | ||
| Token type: TokenType.FUNGIBLE_COMMON | ||
| Args: |
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.
We use args and returns a lot in our docstrings, they are great
However, in this case we do not need them - they are only needed for functions, as these are the ones that pass arguments and returns
For token type which is a class, we do not have return types or args, so can delete this section
- Add comprehensive docstring explaining fungible vs non-fungible tokens - Provide use cases and examples for each token type - Update changelog entry Fixes #1392 Signed-off-by: cheese-cakee <[email protected]>
Fix RUF002 linting error by replacing – with - in docstring to comply with code style guidelines. Signed-off-by: cheese-cakee <[email protected]>
- Add comprehensive Google-style docstring with Attributes, Examples, Args, Returns sections - Include practical example usage for better developer understanding - Maintain existing functionality while improving documentation quality Addresses maintainer feedback for better docstring format Signed-off-by: cheese-cakee <[email protected]>
- Both PRs are up to date with latest changes - No actual merge conflicts detected - Documentation improvements implemented as requested by maintainer
- Removed Args/Returns sections from enum classes as they don't accept parameters - Fixed indentation to follow Google-style docstring format - Maintained comprehensive Examples and Attributes sections
|
Hi @cheese-cakee I would recommend starting a fresh branch git checkout main
git fetch upstream
git pull upstream main
git push originLastly, create a branch: git checkout -b my-new-branch-name |

Summary
TokenTypeenum explaining fungible vs non-fungible tokensReferences
Fixes #1392