Fix sub-project separators are incorrectly quoted in generated URLs (#584)

This commit is contained in:
allegroai 2022-03-21 22:51:27 +02:00
parent 24cdefb8c5
commit 619d59ea2e
2 changed files with 2 additions and 2 deletions

View File

@ -516,7 +516,7 @@ class Task(IdObjectBase, AccessMixin, SetupUploadMixin):
return a_name
return '{}.{}'.format(a_name[:max(2, max_length-len(uuid)-1)], uuid)
return '/'.join(quote(x, safe="'[]{}()$^,.; -_+-=") for x in
return '/'.join(quote(x, safe="'[]{}()$^,.; -_+-=/") for x in
(limit_folder_name(self.get_project_name(), str(self.project), 256, False),
limit_folder_name(self.name, str(self.data.id), 128, True),
extra_path) if x)

View File

@ -41,7 +41,7 @@ def get_config_object_matcher(**patterns):
def quote_url(url):
parsed = urlparse(url)
if parsed.scheme not in ('http', 'https'):
if parsed.scheme not in ("http", "https"):
return url
parsed = parsed._replace(path=quote(parsed.path))
return urlunparse(parsed)