-
Notifications
You must be signed in to change notification settings - Fork 116
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
pulp_file fails to sync file repos literally containing URL encoding strings like %3a in a file name #5686
Comments
In case you want the traceback:
|
Looks like we need to do something like this aio-libs/yarl#1077 However, I am not sure if it's always appropriate. |
I agree, that its pretty "strange" that files are namend like this and including "%3a" digits but from the linux file name standards, this works and therefore pulp "file" should work with it. |
Note: Somebody gave me the following line as a hint: https://github.com/pulp/pulpcore/blob/main/pulpcore/download/http.py#L287-L289 We suspect that this is where pulpcore needs changing. |
Version
Tested using
python3.11-pulp-file-1.15.1
on a Katello instanceDescribe the bug
If a file in a file repo literally contains for example
%3a
in the filename, then this repo cannot be synced to pulp_file, because the download URL unparses the%3a
to:
and runs into a 404, e.g:To Reproduce
I manually create a local file repo as follows:
Here
make_pulp_manifest.sh
is:Feel free to create the PULP_MANIFEST file any other way!
Now serve this file repo somewhere and sync it to pulp_file and observe the sync error.
Expected behavior
Sync succeeds. Not sure how difficult it is to differentiate between a URL that contains URL encodings that should be converted and one like this case where the URL encoding string is literally part of the filename/path.
Additional context
The issue was originally discovered via the real world use case of trying to synchronize a mounted Ubuntu 22.04 iso into pulp_file. Example "problem files" from the mounted Ubuntu iso:
The text was updated successfully, but these errors were encountered: