__init__.py 文件源码

python
阅读 18 收藏 0 点赞 0 评论 0

项目:Marty 作者: NaPs 项目源码 文件源码
def list_backups(self, pattern=None, since=None, until=None):
        labels = self.list_labels()
        for label in labels:
            if pattern is not None and not fnmatch.fnmatchcase(label, pattern):
                continue  # Ignore non matching labels

            try:
                backup = self.get_backup(label)
            except MartyObjectDecodeError:
                continue  # Ignore non-backup labels

            if since is not None and backup.start_date < since:
                continue  # Ignore backups before since date

            if until is not None and backup.start_date > until:
                continue  # Ignore backups before until date

            yield label, backup
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号