ShahriyarR / MySQL-AutoXtraBackup

MySQL-AutoXtraBackup commandline tool written in Python 3 based on Percona XtraBackup
https://autoxtrabackup.azepug.az/
MIT License
139 stars 79 forks source link

Update generalops.py #451

Closed Big-Ele closed 2 years ago

Big-Ele commented 2 years ago

fix bug: File "/usr/local/lib/python3.6/dist-packages/mysql_autoxtrabackup/backup_backup/backup_archive.py", line 142, in clean_old_archives

= float(str(self.backup_archive_options.get("archive_max_duration"))) ValueError: could not convert string to float: 'None'

sourcery-ai[bot] commented 2 years ago

Sourcery Code Quality Report

Merging this PR leaves code quality unchanged.

Quality metrics Before After Change
Complexity 2.85 ⭐ 2.85 ⭐ 0.00
Method Length 63.40 🙂 63.40 🙂 0.00
Working memory 5.83 ⭐ 5.83 ⭐ 0.00
Quality 79.13% 79.13% 0.00%
Other metrics Before After Change
Lines 134 134 0
Changed files Quality Before Quality After Quality Change
mysql_autoxtrabackup/general_conf/generalops.py 79.13% ⭐ 79.13% ⭐ 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/general_conf/generalops.py GeneralClass.backup_archive_options 8 ⭐ 126 😞 7 🙂 64.41% 🙂 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:

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 commented 2 years ago

Fixed in release_v2.0.3 -> again it seems to be fixed.