diff options
-rw-r--r-- | app.py | 14 |
1 files changed, 0 insertions, 14 deletions
@@ -31,20 +31,7 @@ def index_lpuser(LPUSER): def index_ppa(LPUSER, PPA): lpuser = launchpad.people[LPUSER] - runs = [] - ppa = next(filter(lambda p: p.name == PPA, lpuser.ppas)) - series_set = set() - for source_pkg in ppa.getPublishedSources(): - series_set.add(source_pkg.distro_series.name) - - for series in series_set: - RELEASE = series - - try: - urlopen(f"https://autopkgtest.ubuntu.com/results/autopkgtest-{RELEASE}-{LPUSER}-{PPA}/?format=json").read() - except urllib.error.HTTPError: - continue return jsonify(list(set([pkg.source_package_name for pkg in ppa.getPublishedSources()]))) @@ -68,7 +55,6 @@ def index_package(LPUSER, PPA, PACKAGE): @app.route("/<LPUSER>/<PPA>/<PACKAGE>/<RELEASE>") def index_release(LPUSER, PPA, PACKAGE, RELEASE): autopkgtest_url_base = f"https://autopkgtest.ubuntu.com/results/autopkgtest-{RELEASE}-{LPUSER}-{PPA}" - data = json.loads(urlopen(f"{autopkgtest_url_base}?format=json").read()) try: data = json.loads(urlopen(f"https://autopkgtest.ubuntu.com/results/autopkgtest-{RELEASE}-{LPUSER}-{PPA}/?format=json").read()) except urllib.error.HTTPError: |