Skip to content

Commit

Permalink
Merge pull request #120 from imodpasteur/quote-url
Browse files Browse the repository at this point in the history
Quote URL
  • Loading branch information
oeway authored Aug 31, 2022
2 parents c895eb3 + 080cb3c commit 7c766c2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion shareloc_utils/VERSION
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"version": "0.1.9"
"version": "0.1.10"
}
6 changes: 3 additions & 3 deletions shareloc_utils/batch_download.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import yaml
import fnmatch
import urllib.request
from urllib.parse import urljoin
from urllib.parse import urljoin, quote
import tempfile
import shutil

Expand Down Expand Up @@ -170,7 +170,7 @@ def download(
if name:
# download the file
download_url(
resolve_url(rdf_url, sample["name"] + "/" + name),
resolve_url(rdf_url, quote(sample["name"]) + "/" + quote(name)),
file_path,
)

Expand All @@ -186,7 +186,7 @@ def download(
):
# download the file
download_url(
resolve_url(rdf_url, sample["name"] + "/" + file["name"]),
resolve_url(rdf_url, quote(sample["name"]) + "/" + quote(file["name"])),
file_path,
)
# optionally, convert .smlm file to text file
Expand Down

0 comments on commit 7c766c2

Please sign in to comment.