Message ID | 20250530100816.737484-1-marcin.bajer@salwatorska.pl (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | bitbake: wget.py: Fix missing uri query parameters in uri creation in checkstatus method | expand |
On Fri, 30 May 2025 at 12:08, Marcin Bajer via lists.yoctoproject.org <marcin.bajer=salwatorska.pl@lists.yoctoproject.org> wrote: > > Appends missing query parameters to uri in checkstatus method. This needs to go to bitbake-devel list. Alex
diff --git a/bitbake/lib/bb/fetch2/wget.py b/bitbake/lib/bb/fetch2/wget.py index 7e43d3bc97..93e902d8f8 100644 --- a/bitbake/lib/bb/fetch2/wget.py +++ b/bitbake/lib/bb/fetch2/wget.py @@ -373,6 +373,8 @@ class Wget(FetchMethod): try: parts = urllib.parse.urlparse(ud.url.split(";")[0]) uri = "{}://{}{}".format(parts.scheme, parts.netloc, parts.path) + if urllib.parse.urlparse(uri_base).query: + uri += "?{}".format(urllib.parse.urlparse(uri_base).query) r = urllib.request.Request(uri) r.get_method = lambda: "HEAD" # Some servers (FusionForge, as used on Alioth) require that the
Appends missing query parameters to uri in checkstatus method. With commit 89ccf603d8119c34f5398dbd737e6a0b805234d3 all query parameters are removed. This breaks az.py fetcher in case of using SAS authenicated access. To check if blob exists SAS token needs to be addes to URL (https://learn.microsoft.com/en-us/azure/storage/common/storage-sas-overview#sas-token) Fixes #15299 Signed-off-by: Marcin Bajer <marcin.bajer@salwatorska.pl> --- bitbake/lib/bb/fetch2/wget.py | 2 ++ 1 file changed, 2 insertions(+)