osmith has uploaded this change for review.

View Change

src/grd: urlencode / in project names

Fix that it didn't work with projects that contain a slash character,
such as erlang/osmo-epdg.

Change-Id: I810d6d0654ab8f3019c00e32762edfef7e7350a7
---
M src/grd
1 file changed, 15 insertions(+), 1 deletion(-)

git pull ssh://gerrit.osmocom.org:29418/osmo-dev refs/changes/65/36765/1
diff --git a/src/grd b/src/grd
index 0ca5df7..e149c6f 100755
--- a/src/grd
+++ b/src/grd
@@ -9,6 +9,7 @@
import os
import subprocess
import urllib.request
+import urllib.parse


def get_topdir():
@@ -37,7 +38,8 @@


def get_gerrit_details(host, project, patch_id, verbose):
- url = f"https://{host}/changes/{project}~{args.patch_id}/detail"
+ project_q = urllib.parse.quote(project, "")
+ url = f"https://{host}/changes/{project_q}~{args.patch_id}/detail"
print(f"Download {url}")
with urllib.request.urlopen(url) as response:
content = response.read().decode()

To view, visit change 36765. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: osmo-dev
Gerrit-Branch: master
Gerrit-Change-Id: I810d6d0654ab8f3019c00e32762edfef7e7350a7
Gerrit-Change-Number: 36765
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith@sysmocom.de>
Gerrit-MessageType: newchange