Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<a href>'s unescaped differently dependent on locale #27

Open
OrIdow6 opened this issue Dec 14, 2024 · 1 comment
Open

<a href>'s unescaped differently dependent on locale #27

OrIdow6 opened this issue Dec 14, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@OrIdow6
Copy link
Collaborator

OrIdow6 commented Dec 14, 2024

echo '<html><body><a href="%2525CCfile.html" /></body></html>' > file.html
python3 -m http.server 8888 &
env -i ../wget-lua/src/wget -nv --recursive http://127.0.0.1:8888/file.html
env -i LANG=en_US.UTF-8 ../wget-lua/src/wget -nv --recursive http://127.0.0.1:8888/file.html

The outputs are respectively

...
2024-12-13 16:48:29 ERROR 404: File not found.
127.0.0.1 - - [13/Dec/2024 16:48:29] "GET /%25CCfile.html HTTP/1.1" 404 -
http://127.0.0.1:8888/%25CCfile.html:
2024-12-13 16:48:29 ERROR 404: File not found.
...

and

...
2024-12-13 16:48:52 ERROR 404: File not found.
127.0.0.1 - - [13/Dec/2024 16:48:52] code 404, message File not found
127.0.0.1 - - [13/Dec/2024 16:48:52] "GET /%2525CCfile.html HTTP/1.1" 404 -
http://127.0.0.1:8888/%2525CCfile.html:
2024-12-13 16:48:52 ERROR 404: File not found.
...

Notice the difference in the filenames it tries to GET.
The behavior of the second is the one I wanted (I don't know if it's correct according to standards, but I hope that it is), but the first is what we get in warrior projects because something in Seesaw clears the environment.

My dev environment is not the official Docker image and there's a small chance that a difference between my installation and that is causing this; but this did come to my attention due to a crash in someone running a production Cohost script so that seems unlikely.

May investigate this myself but Cohost seems liable to go down soon so that can wait.

@OrIdow6 OrIdow6 added the bug Something isn't working label Dec 14, 2024
@OrIdow6
Copy link
Collaborator Author

OrIdow6 commented Dec 14, 2024

(This is not an issue with displaying the URLs in wget's output; the same thing happens if you print them in download_child_p or have the link go to a "server" on a port with a listening netcat)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant