Reset branch if the devel branch is based on Factory

This happens in packages that change their devel project over time. Then
the commit in the devel project no longer has the parent in the devel branch
but is based on factory
This commit is contained in:
Stephan Kulow
2022-11-03 10:37:26 +01:00
parent f5b3e42165
commit ed4b7367eb
5 changed files with 50 additions and 48 deletions

View File

@@ -5,11 +5,10 @@ import time
import urllib.parse
import xml.etree.ElementTree as ET
from urllib.error import HTTPError
from pathlib import Path
from lib.proxy_sha256 import md5
import osc.core
from lib.proxy_sha256 import md5
from lib.request import Request
from lib.user import User
@@ -164,7 +163,7 @@ class OBS:
cachedir: str,
file_md5: str,
) -> None:
cached_file = self._path_from_md5(name, cachedir, file_md5)
if not self.in_cache(name, cachedir, file_md5):
with (dirpath / name).open("wb") as f: