jefftriplett / kindlestrip

:book: A pip-installable conversion of Paul Durrant's kindlestrip
https://www.mobileread.com/forums/showthread.php?t=96903
The Unlicense
67 stars 10 forks source link

Sourcery Starbot ⭐ refactored jefftriplett/kindlestrip #5

Open sourcery-ai-bot opened 3 years ago

sourcery-ai-bot commented 3 years ago

Thanks for starring sourcery-ai/sourcery ✨ 🌟 ✨

Here's your pull request refactoring your most popular Python repo.

If you want Sourcery to refactor all your Python repos and incoming pull requests install our bot.

Review changes via command line

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

git fetch https://github.com/sourcery-ai-bot/kindlestrip master
git merge --ff-only FETCH_HEAD
git reset HEAD^
sourcery-ai[bot] commented 3 years ago

Sourcery Code Quality Report

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

Quality metrics Before After Change
Complexity 2.00 ⭐ 2.00 ⭐ 0.00
Method Length 31.00 ⭐ 29.89 ⭐ -1.11 👍
Working memory 4.78 ⭐ 4.67 ⭐ -0.11 👍
Quality 89.66% 90.13% 0.47% 👍
Other metrics Before After Change
Lines 138 133 -5
Changed files Quality Before Quality After Quality Change
kindlestrip.py 89.66% ⭐ 90.13% ⭐ 0.47% 👍

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

File Function Complexity Length Working Memory Quality Recommendation
kindlestrip.py utf8_argv 14 🙂 151 😞 10 😞 49.59% 😞 Try splitting into smaller methods. Extract out complex expressions
kindlestrip.py SRCSStripper.sec_info 2 ⭐ 53 ⭐ 14 😞 67.40% 🙂 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!

Let us know what you think of it by mentioning @sourcery-ai in a comment.