Skip to content
Snippets Groups Projects
Commit 1eb0f23f authored by Nik | Klampfradler's avatar Nik | Klampfradler
Browse files

Merge branch '478-backup-health-check-broken-due-to-missing-mathematical-knowledge' into 'master'

Resolve "Backup health check broken due to missing mathematical knowledge"

Closes #478

See merge request !658
parents c6c2c474 b0ba33a9
No related branches found
No related tags found
1 merge request!658Resolve "Backup health check broken due to missing mathematical knowledge"
Pipeline #16590 passed
Pipeline: AlekSIS

#16592

    ......@@ -6,6 +6,14 @@ All notable changes to this project will be documented in this file.
    The format is based on `Keep a Changelog`_,
    and this project adheres to `Semantic Versioning`_.
    Unreleased
    ----------
    Fixed
    ~~~~~
    * Fix broken backup health check
    `2.0b1`_ - 2021-06-01
    ---------------------
    ......
    ......@@ -38,9 +38,9 @@ class BaseBackupHealthCheck(BaseHealthCheckBackend):
    self.add_error(_("The backup folder doesn't exist."))
    return
    if backups:
    last_backup = backups[-1]
    last_backup_time = dbbackup_utils.filename_to_date(last_backup)
    time_gone_since_backup = last_backup_time - datetime.now()
    last_backup = backups[:1]
    last_backup_time = dbbackup_utils.filename_to_date(last_backup[0])
    time_gone_since_backup = datetime.now() - last_backup_time
    # Check if backup is older than configured time
    if time_gone_since_backup.seconds > self.configured_seconds:
    ......
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Finish editing this message first!
    Please register or to comment