QA Report #42
Labels
bug
Something isn't working
QA (Quality Assurance)
Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax
sponsor confirmed
Sponsor agrees this is a problem and intends to fix it (OK to use w/ "disagree with severity")
Mixed Use of Custom Errors and
require(condition, "msg"
Severity: Informational
Context:
Witch.sol
Description:
It's better to stick to one or the other to stay consistent.
Recommendation:
I would recommend the use of just custom errors to save gas on deployment.
otherWitches
Possible Name SuggestionSeverity: Informational
Context:
Witch.sol#L68
Description:
"The name is a bit misleading, as any address can be entered. Better naming suggestions are welcome."
Recommendation:
Maybe
Witched
,VaultTaken
,bewitched
orhexed
Contract Code Size Exceeds Bytes Limit
Severity: Informational
Context:
Witch.sol
Description:
Contract code size is 28515 bytes and exceeds 24576 bytes (a limit introduced in Spurious Dragon). This contract may not be deployable on mainnet.
Recommendation:
Consider enabling the optimizer (with a low "runs" value!), turning off revert strings, or using libraries.
TODOs Left In The Code
Severity: Informational
Context:
Witch.sol#L577
Description:
There should never be any TODOs in the code when deploying.
Recommendation:
Add this TODO to the docs instead.
Spelling Errors
Severity: Informational
Context:
Witch.sol#L213 (overriden => overridden)
,Witch.sol#L220 (repayed => repaid)
,Witch.sol#L267 (overriden => overridden)
,Witch.sol#L267 (differente => different)
,Witch.sol#L462 (overriden => overridden)
,Witch.sol#L512 (Delete the extra space)
,Witch.sol#L520 (quoutes => quotes)
,Witch.sol#L520 (hoy => how)
Description:
Spelling errors in comments can cause confusion to both users and developers.
Recommendation:
Check all misspellings to ensure they are corrected.
Missing or Incomplete NatSpec
Severity: Informational
Context:
Witch.sol
Description:
Some functions are missing @notice/@dev NatSpec comments for the function, @param for all/some of their parameters and @return for return values. Given that NatSpec is an important part of code documentation, this affects code comprehension, auditability and usability.
Recommendation:
Add in full NatSpec comments for all functions to have complete code documentation for future use.
The text was updated successfully, but these errors were encountered: