Skip to content
This repository has been archived by the owner on May 9, 2023. It is now read-only.

Major refactorings - iteration 1 #458

Open
wants to merge 13 commits into
base: release_v2.0.3
Choose a base branch
from
Open

Major refactorings - iteration 1 #458

wants to merge 13 commits into from

Conversation

ShahriyarR
Copy link
Owner

No description provided.

@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Apr 13, 2022

Sourcery Code Quality Report

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

Quality metrics Before After Change
Complexity 6.28 ⭐ 2.47 ⭐ -3.81 👍
Method Length 59.29 ⭐ 36.09 ⭐ -23.20 👍
Working memory 8.80 🙂 7.08 🙂 -1.72 👍
Quality 68.93% 🙂 80.51% 11.58% 👍
Other metrics Before After Change
Lines 2954 1035 -1919
Changed files Quality Before Quality After Quality Change
changes/make_history.py 36.02% 😞 36.02% 😞 0.00%
docs/conf.py 73.00% 🙂 73.00% 🙂 0.00%
mysql_autoxtrabackup/init.py 100.00% ⭐ 100.00% ⭐ 0.00%
mysql_autoxtrabackup/autoxtrabackup.py 45.55% 😞 84.77% ⭐ 39.22% 👍
mysql_autoxtrabackup/api/main.py 93.44% ⭐ 93.44% ⭐ 0.00%
mysql_autoxtrabackup/api/controller/controller.py 85.77% ⭐ 85.77% ⭐ 0.00%
mysql_autoxtrabackup/process_runner/errors.py 95.95% ⭐ 96.04% ⭐ 0.09% 👍
mysql_autoxtrabackup/process_runner/process_runner.py 70.99% 🙂 74.97% 🙂 3.98% 👍
tests/conftest.py 98.67% ⭐ 87.90% ⭐ -10.77% 👎
tests/test_backup.py 88.77% ⭐ 88.77% ⭐ 0.00%
tests/test_helpers.py 89.46% ⭐ 89.46% ⭐ 0.00%
tests/test_mysql_cli.py 96.05% ⭐ 96.05% ⭐ 0.00%

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

File Function Complexity Length Working Memory Quality Recommendation
mysql_autoxtrabackup/autoxtrabackup.py all_procedure 0 ⭐ 238 ⛔ 41 ⛔ 39.67% 😞 Try splitting into smaller methods. Extract out complex expressions
mysql_autoxtrabackup/process_runner/process_runner.py ProcessHandler.summarize_process 7 ⭐ 85 🙂 12 😞 60.59% 🙂 Extract out complex expressions
mysql_autoxtrabackup/autoxtrabackup.py _handle_backup_pid_exception 2 ⭐ 83 🙂 14 😞 62.80% 🙂 Extract out complex expressions
mysql_autoxtrabackup/autoxtrabackup.py _build_callables_map 4 ⭐ 54 ⭐ 12 😞 68.24% 🙂 Extract out complex expressions

Legend and Explanation

The emojis denote the absolute quality of the code:

  • ⭐ excellent
  • 🙂 good
  • 😞 poor
  • ⛔ very poor

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!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant