Open maaaaz opened 3 weeks ago
Hi, thanks for letting me know. I'll try to look at it ASAP 😅
Tried to make a new version with a partial fix, and maybe the definitive fix for now. But GitHub wont let me anymore because they deprecated/disabled older build actions. Will continue another time..
I think this should be optional (but maybe the default). I've encountered servers in the past that didn't treat encoded URLs the same as the raw URL, seemingly becaus they didn't decode them (or not correctly). Improving the parsing in the downloadet itself, or manually passing an enquoted URL to it, should work even with URLs that aren't encoded.
I think this should be default, as download managers do not support unencoded URLs.
In the meantime, a Python solution to properly encode ODD output file:
$ cat script.py
#!/usr/bin/python3
import sys
import urllib.parse
for line in sys.stdin:
print(urllib.parse.quote(line.strip(), safe=':/'))
$ cat oddresult | python script.py
Hello there,
I observe that even the latest current version of ODD (v3.1.0.1) does not properly encode URL in the output file.
Let me detail the case:
First, let's ODD a (randomly found on the internet) website containing some special chars in the path:
Then let's see the first results of the output file:
If we try to download the first file with
wget
(and even other download managers), it fails because there are unencoded characters in the URL: "#" and whitespaces.index.html 100%[===============================================================================>] 844 --.-KB/s in 0s
2024-10-29 23:22:13 (550 MB/s) - ‘index.html’ saved [844/844]