utils.studio: allow any base url to be set, not just the hostname (#9341)

This keeps it in symmetry with
https://github.com/iterative/dvc-studio-client/pull/28, and allows
setting the base url with path, not just limited to netloc.

This was always intended to work, urljoin with the added slash was
causing this bug.
This commit is contained in:
skshetry
2023-04-18 22:22:26 +05:45
committed by GitHub
parent dd3deb6cbd
commit 5563a595d5
+1 -1
View File
@@ -57,7 +57,7 @@ def notify_refs(
data = {"repo_url": repo_url, "client": "dvc", "refs": refs}
try:
r = post("/webhook/dvc", token, data, base_url=base_url)
r = post("webhook/dvc", token, data, base_url=base_url)
except requests.RequestException as e:
logger.trace("", exc_info=True) # type: ignore[attr-defined]