-
Notifications
You must be signed in to change notification settings - Fork 30
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
File-Editor: Can't open files with multi-byte UTF-8 characters #671
Comments
➤ Jeremy Nicklas commented: The viewer in FileExplorer works though. So this only seems to affect opening files in FileEditor. |
➤ Brian L. McMichael commented: This one is turning out to be a little sticky. Using the example: (ノ°Д°)ノ︵ ┻━┻ is actually causing problems on the Rails end. On the system, ) is actually a three-byte char represented by %EF%BC%89, but the ruby renderer is writing it out as a standard close paren ), which doesn't get escaped. Likewise ︵ is represented by %EF%B8%B5 and it's being rendered as ( These are valid characters on the filesystem and I can open the files in the File Explorer viewer, but because rails (or maybe the browser) is making some odd substitutions as or before it gets rendered out, it's not encoding properly prior to getting passed to the API. I'll need to pinpoint exactly where the substitution is happening and enforce the proper encoding. |
➤ Brian L. McMichael commented: The problem seems to be coming from the OodAppkit files api generator. There may be a setting required for Addressible gem to handle this appropriately.irb(main):002:0> p = Pathname.new '(ノ°Д°)ノ︵ ┻━┻' |
➤ Brian L. McMichael commented: Appears to affect Addressible 2.5.1Addressable::URI.parse('http://www.google.com/(╯°□°)╯︵ ( http://www.google.com/(╯°□°)╯︵ ) ┻━┻').normalize |
➤ Brian L. McMichael commented: The problem with Addressable seems intentional.
sporkmonger/addressable#8 (comment) ( sporkmonger/addressable#8 (comment) ) nickjer is the .normalize call in OodAppkit necessary? irb(main):003:0> p = Pathname.new "http://www.google.com/(╯°□°)╯︵ ( http://www.google.com/(╯°□°)╯︵ ) ┻━┻" |
➤ Jeremy Nicklas commented: I say we punt on this and bring up a more url-friendly encoding for file paths that all of our apps implement for ingest. An example being: https://ruby-doc.org/stdlib-2.2.0/libdoc/base64/rdoc/Base64.html in particular the urlsafe option. |
I am unable to open files whether from the FileExplorer or from this internal file explorer that have funky characters in the file name:
┆Issue is synchronized with this Asana task by Unito
The text was updated successfully, but these errors were encountered: