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

Release v2.0.3 #450

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Release v2.0.3 #450

wants to merge 4 commits into from

Conversation

ShahriyarR
Copy link
Owner

No description provided.

…ath (#448)

As discussed in #446 it can be valuable to add an commandline option to generate the default config file is this was somehow eliminated by setup.

--generate-config-file flag option was added. Sample run will be something like this:
autoxtrabackup --generate-config-file --verbose
2021-10-03 19:03:07 INFO [autoxtrabackup:278] Default config file is generated in /home/shako/.autoxtrabackup/autoxtrabackup.cnf
2021-10-03 19:03:07 INFO [autoxtrabackup:313] Xtrabackup command history:
2021-10-03 19:03:07 INFO [autoxtrabackup:315] ['command', 'xtrabackup_function', 'start time', 'end time', 'duration', 'exit code']
2021-10-03 19:03:07 INFO [autoxtrabackup:316] Autoxtrabackup completed successfully!
The wrong config option was used and it fails when the tool tries to use backup archive feature.

Now it will raise BackupArchiveNotConfigured error if options were not set and also it will check for archive_max_duration
@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Oct 3, 2021

Sourcery Code Quality Report

❌  Merging this PR will decrease code quality in the affected files by 0.28%.

Quality metrics Before After Change
Complexity 13.29 🙂 13.40 🙂 0.11 👎
Method Length 67.29 🙂 67.75 🙂 0.46 👎
Working memory 15.57 ⛔ 16.27 ⛔ 0.70 👎
Quality 56.34% 🙂 56.06% 🙂 -0.28% 👎
Other metrics Before After Change
Lines 609 634 25
Changed files Quality Before Quality After Quality Change
mysql_autoxtrabackup/autoxtrabackup.py 46.83% 😞 45.55% 😞 -1.28% 👎
mysql_autoxtrabackup/backup_backup/backup_archive.py 41.62% 😞 40.58% 😞 -1.04% 👎
mysql_autoxtrabackup/general_conf/generalops.py 79.13% ⭐ 81.02% ⭐ 1.89% 👍
mysql_autoxtrabackup/process_runner/errors.py 96.04% ⭐ 95.95% ⭐ -0.09% 👎
mysql_autoxtrabackup/utils/version.py 100.00% ⭐ 100.00% ⭐ 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 27 😞 619 ⛔ 46 ⛔ 11.23% ⛔ Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
mysql_autoxtrabackup/backup_backup/backup_archive.py BackupArchive.create_backup_archives 30 😞 256 ⛔ 11 😞 29.21% 😞 Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
mysql_autoxtrabackup/backup_backup/backup_archive.py BackupArchive.clean_old_archives 15 🙂 169 😞 12 😞 43.33% 😞 Try splitting into smaller methods. Extract out complex expressions
mysql_autoxtrabackup/general_conf/generalops.py GeneralClass.backup_archive_options 4 ⭐ 126 😞 7 🙂 68.28% 🙂 Try splitting into smaller methods
mysql_autoxtrabackup/general_conf/generalops.py GeneralClass.backup_options 0 ⭐ 126 😞 5 ⭐ 77.29% ⭐ Try splitting into smaller methods

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!

@ShahriyarR
Copy link
Owner Author

Remaining is to update doc

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