-
Notifications
You must be signed in to change notification settings - Fork 10
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
Fix forge docs #750
Fix forge docs #750
Conversation
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.
As I was reviewing I found the function _encumberance
to be confusing... If we only ever use this method to determine encumbered collateral I think the comment should indicate that is it's sole use case instead of what we have now ->
Calculates encumberance for a debt amount at a given price.
Names that lack descriptions in forge docs
:
ajnaPool_
inauctionStatus
params
inburn
tokenId_
inclaimRewards
epochToClaim_
inclaimRewards
tokenId_
instake
tokenId_
inunstake
pool_
andindexes_
inupdateBucketExchangeRatesAndClaim
tokenId_
andepochToCLaim_
incalculateRewards
tokenId_
andbucketId_
ingetBucketStateStakeInfo
rewardsClaimedInEpoch_
in_calculateNewRewards
That is a start ^^ there are alot more. Worth manually reviewing versus me typing them all out : )
Pls check with latest, they should be fixed. Takeaway is interface should have same params naming as impl in order to generate docs properly. |
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
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.
Criticisms regarding scope and audit status:
We had some inconsistency with some interfaces having trailing underscores in parameter and return type names, and other interfaces with no trailing underscores. If we had not completed any audits, I would favor no trailing underscores in interfaces.Just read comment interface should have same params naming as impl in order to generate docs properly; understood.- Making
LPs
singular seems outside the purported scope of this change.
Other criticisms:
- I don't see why the term NFT should be backtick-quoted everywhere.
These concerns seem to be forge doc
limitations:
- Not a fan of the
===
sprinkled everywhere, but we seemingly don't have much freedom to adjust formatting inforge doc
output. - Emitted events are not linked to the event definition; reader must hunt to determine arguments.
- Non-exposed methods should not be included in generated documentation.
- Free functions do not appear within the context of their containing library.
There are some valuable documentation improvements within, so in all it's a net positive. I don't think there is value adding a Makefile
target. Happy to approve after a few minor inline concerns are addressed.
Yeah, just wanted to make them inline with
was the best way I found to highlight different sections, can use different separator if there's a nicer one |
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.
Looks good; thanks for this tedious work.
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
forge doc --serve --port 4000
and navigate to http://localhost:4000/