Refactor __init__.py:discover_commands(logging)
Closed this issue ยท 0 comments
plainenough commented
I've selected init.py:discover_commands(logging) for refactoring, which is a unit of 23 lines of code and 5 branch points. Addressing this will make our codebase more maintainable and improve Better Code Hub's Write Simple Units of Code guideline rating! ๐
Here's the gist of this guideline:
- Definition ๐
Limit the number of branch points (if, for, while, etc.) per unit to 4. - Whyโ
Keeping the number of branch points low makes units easier to modify and test. - How ๐ง
Split complex units with a high number of branch points into smaller and simpler ones.
You can find more info about this guideline in Building Maintainable Software. ๐
โน๏ธ To know how many other refactoring candidates need addressing to get a guideline compliant, select some by clicking on the ๐ฒ next to them. The risk profile below the candidates signals (โ ) when it's enough! ๐
Good luck and happy coding! โจ ๐ฏ