JakubAndrysek / MkDoxy

📖 Automatically generates API documentation for your project based on Doxygen comments and code snippets in your markdown files.
https://mkdoxy.kubaandrysek.cz/
MIT License
60 stars 16 forks source link

Watch doxygen (Sourcery refactored) #24

Closed sourcery-ai[bot] closed 2 years ago

sourcery-ai[bot] commented 2 years ago

Pull Request #23 refactored by Sourcery.

If you're happy with these changes, merge this Pull Request using the Squash and merge strategy.

NOTE: As code is pushed to the original Pull Request, Sourcery will re-run and update (force-push) this Pull Request with new refactorings as necessary. If Sourcery finds no refactorings at any point, this Pull Request will be closed automatically.

See our documentation here.

Run Sourcery locally

Reduce the feedback loop during development by using the Sourcery editor plugin:

Review changes via command line

To manually merge these changes, make sure you're on the watch-doxygen branch, then run:

git fetch origin sourcery/watch-doxygen
git merge --ff-only FETCH_HEAD
git reset HEAD^

Help us improve this pull request!

sourcery-ai[bot] commented 2 years ago

Sourcery Code Quality Report

✅  Merging this PR will increase code quality in the affected files by 0.86%.

Quality metrics Before After Change
Complexity 20.62 😞 19.83 😞 -0.79 👍
Method Length 42.25 ⭐ 41.66 ⭐ -0.59 👍
Working memory 10.10 😞 9.80 🙂 -0.30 👍
Quality 61.54% 🙂 62.40% 🙂 0.86% 👍
Other metrics Before After Change
Lines 2078 1991 -87
Changed files Quality Before Quality After Quality Change
doxygen_snippets/doxygen.py 54.77% 🙂 55.61% 🙂 0.84% 👍
doxygen_snippets/finder.py 77.32% ⭐ 76.12% ⭐ -1.20% 👎
doxygen_snippets/generatorBase.py 62.60% 🙂 65.79% 🙂 3.19% 👍
doxygen_snippets/generatorSnippets.py 72.79% 🙂 73.14% 🙂 0.35% 👍
doxygen_snippets/markdown.py 93.50% ⭐ 93.51% ⭐ 0.01% 👍
doxygen_snippets/node.py 62.82% 🙂 63.86% 🙂 1.04% 👍
doxygen_snippets/plugin.py 40.24% 😞 39.67% 😞 -0.57% 👎
doxygen_snippets/utils.py 71.41% 🙂 74.35% 🙂 2.94% 👍
doxygen_snippets/xml_parser.py 24.62% ⛔ 25.20% 😞 0.58% 👍

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
doxygen_snippets/xml_parser.py XmlParser.paras 118 ⛔ 966 ⛔ 28 ⛔ 1.26% ⛔ Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
doxygen_snippets/node.py Node.codeblock 57 ⛔ 356 ⛔ 16 ⛔ 11.55% ⛔ Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
doxygen_snippets/node.py Node._check_for_children 49 ⛔ 459 ⛔ 10 😞 20.49% ⛔ Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
doxygen_snippets/plugin.py DoxygenSnippets.on_files 23 😞 364 ⛔ 15 😞 23.80% ⛔ Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
doxygen_snippets/node.py Node.__init__ 15 🙂 381 ⛔ 17 ⛔ 27.28% 😞 Try splitting into smaller methods. Extract out complex expressions

Legend and Explanation

The emojis denote the absolute quality of the code:

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Help us improve this quality report!