From: William Lallemand Date: Tue, 13 Aug 2024 14:43:03 +0000 (+0200) Subject: BUG/MINOR: release-estimator: fix relative scheme in CHANGELOG URL X-Git-Tag: v3.1-dev6~48 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=bb02d95e9219119ab00f89c3c5580f3dfa71a336;p=thirdparty%2Fhaproxy.git BUG/MINOR: release-estimator: fix relative scheme in CHANGELOG URL The CHANGELOG URL which is parsed in the HTML now have a relative scheme, which is incompatible with requests. This patch adds an https scheme to the URL. --- diff --git a/admin/release-estimator/release-estimator.py b/admin/release-estimator/release-estimator.py index bf005df3fa..e113bffcbd 100755 --- a/admin/release-estimator/release-estimator.py +++ b/admin/release-estimator/release-estimator.py @@ -16,6 +16,7 @@ # from lxml import html +from urllib.parse import urljoin import requests import traceback import smtplib @@ -190,6 +191,7 @@ This is a friendly bot that watches fixes pending for the next haproxy-stable re # parse out the CHANGELOG link CHANGELOG = tree.xpath('//a[contains(@href,"CHANGELOG")]/@href')[0] + CHANGELOG = urljoin("https://", CHANGELOG) last_version = tree.xpath('//td[contains(text(), "last")]/../td/a/text()')[0] first_version = "%s.0" % (version)