Repository navigation
Multiple fixes for path-related issues and other stuff... - #1419
Conversation
Fix Difegue#1410 Fix Difegue#1418 Added get_archive_path for getting the archive path without going through create_path every time. Better handling of special characters when uploading files.
| # Add the file to the database ourselves so Shinobu doesn't do it | ||
| # This allows autoplugin to be ran ASAP. | ||
| my $name = add_archive_to_redis( $id, $output_file, $redis, $redis_search ); | ||
| my $name = add_archive_to_redis( $id, redis_encode( redis_decode( $output_file ) ), $redis, $redis_search ); |
There was a problem hiding this comment.
I'm quite wary of this PR making changes to effectively store encoded filenames in Redis instead of raw bytes from the FS - Historically not using the exact filepaths the host filesystem caused a ton of issues on systems with weird locales.
746ee52 to
69638f0
Compare
|
Current state of the encoding issues in this pr: Linux has working encoding in both api and web uploads, both match and behave the same during testing. Windows has working encoding for web uploads. The api will process the files in the wrong encoding, but when they are moved into the content folder Shinobu automatically fixes the paths to the correct fs encoding. ID generation is not affected by the encoding and file operations continue to work. I don't have leads or ideas or anything that could explain said behavior, I literally have no idea what the hell is going on. Previous to this I did not test the upload api so for all I know it might be completely broken in prod on Windows (Not that anyone is using it). Up to you dfug if you want me to keep or remove the encoding changes. |
|
Given the test results I think this will work out ok for 95% of setups, and has the perk of cleaning up the old minion jank -- Let's try it out and see how it goes. |
Win32::FileSystemHelper diff