From 2d63b4fe930a408c29d265e7f8758e2017fbbd96 Mon Sep 17 00:00:00 2001 From: Dominik Heidler Date: Mon, 24 Mar 2025 16:30:29 +0100 Subject: [PATCH] requests: Support file:// scheme for local files. This allows installing packages using mip from an index served from the local fs. Signed-off-by: Dominik Heidler --- python-ecosys/requests/requests/__init__.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/python-ecosys/requests/requests/__init__.py b/python-ecosys/requests/requests/__init__.py index 2951035f7..20a88a2ab 100644 --- a/python-ecosys/requests/requests/__init__.py +++ b/python-ecosys/requests/requests/__init__.py @@ -71,6 +71,10 @@ def request( import tls port = 443 + elif proto == "file:": + r = Response(open(url[7:], "b")) + r.status_code = 200 + return r else: raise ValueError("Unsupported protocol: " + proto) pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy