Issue with files containing the # symbol in the name

Hello! I’m not sure if this issue has been raised before. It’s impossible to work with files containing the # symbol in their names.

For example:

  • fs.lstat('path/to/#1.jpg') parses the path only up to the #, so .isFile() returns false.
  • Similarly, the module storage.localFileSystem.getEntryWithUrl(path/to/#1.jpg) behaves the same way.

It’s also impossible to rename such files using UPX. However, the # symbol is allowed in file names on both macOS and Windows. Is this a bug? :slight_smile: Issue with files containing the # symbol in the name Issue with files containing the # symbol in the name

1 Like

It seems I have found a solution. If you apply encodeURIComponent('#1.jpg') to the name (or full path) with this symbol, then everything works as it should.

1 Like

I also observed same issue: @uxp.bereza.cz on Bluesky

Also if you list files in that directory it will return list of first parent existing directory instead.

In NodeJS it fails correctly.

1 Like