Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

function smartRemoveList missing return value #1392

Closed
buhtz opened this issue Dec 21, 2022 · 0 comments · Fixed by #1458
Closed

function smartRemoveList missing return value #1392

buhtz opened this issue Dec 21, 2022 · 0 comments · Fixed by #1458
Assignees
Labels
Bug Low relevant, but not urgent
Milestone

Comments

@buhtz
Copy link
Member

buhtz commented Dec 21, 2022

That was originally reported at Debian Bug Tracker on Nov. 2020.
Nothing serious.

Package: backintime-common
Version: 1.2.1-2
Severity: normal

Dear Maintainer,

Happened to be borwsing the class Snapshots in function smartRemoveList

   if len(snapshots) <= 1:
        logger.debug("There is only one snapshots, so keep it", self)
        return

should maybe return the empty list

Related code location

backintime/common/snapshots.py

Lines 1350 to 1354 in e36d8dc

snapshots = listSnapshots(self.config)
logger.debug("Considered: %s" %snapshots, self)
if len(snapshots) <= 1:
logger.debug("There is only one snapshots, so keep it", self)
return

@buhtz buhtz added Bug Low relevant, but not urgent labels Dec 21, 2022
@buhtz buhtz added this to the 1.3.4 milestone Dec 21, 2022
@buhtz buhtz self-assigned this Apr 5, 2023
buhtz added a commit that referenced this issue Jun 30, 2023
The method computing a list of snapshots that are ready to get removed now returns an empty list if it can't find a snapshot to remove. Minor PEP8 formatting.

Fix Debian-Bug 973760
Fix #1392
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Low relevant, but not urgent
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant