discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

Heads up: fixes for non-ASCII file names

JB
Jordan Brown
Thu, Nov 20, 2025 6:20 PM

My PR#6136 https://github.com/openscad/openscad/pull/6136 (which will
hit the development snapshot in a day or two) fixes a number of problems
with non-ASCII file names on Windows.

It doesn't fix all of them - the biggest remaining is that there are
problems with non-ASCII directory names - but it fixes some.  See the
PR for known outstanding issues.

It's not expected to make any difference on Linux or MacOS, but it's
possible that it will cause problems for non-ASCII names in non-UTF-8
environments.  If there are such problems that cause real-world issues,
let me know.  (Come on, it's 2025, get with the program!)

Please keep an eye out for any problems, especially any problems where
something that used to work stops working.

Unfortunately, there were a lot of problems with non-ASCII names, and
when you fix 80 or 90% of "a lot", you still have "a lot".  Please file
new issues for cases that still have problems.

My PR#6136 <https://github.com/openscad/openscad/pull/6136> (which will hit the development snapshot in a day or two) fixes a number of problems with non-ASCII file names on Windows. It doesn't fix all of them - the biggest remaining is that there are problems with non-ASCII *directory* names - but it fixes some.  See the PR for known outstanding issues. It's not expected to make any difference on Linux or MacOS, but it's possible that it will cause problems for non-ASCII names in non-UTF-8 environments.  If there are such problems that cause real-world issues, let me know.  (Come on, it's 2025, get with the program!) Please keep an eye out for any problems, especially any problems where something that used to work stops working. Unfortunately, there were a lot of problems with non-ASCII names, and when you fix 80 or 90% of "a lot", you still have "a lot".  Please file new issues for cases that still have problems.
JB
Jordan Brown
Fri, Nov 21, 2025 3:20 AM

On 11/20/2025 10:20 AM, Jordan Brown wrote:

It doesn't fix all of them - the biggest remaining is that there are
problems with non-ASCII directory names

Having gotten that wad of changes off my plate, I looked at the next
thing, which is the problem with non-ASCII directory names.

That problem turns out (#6382
https://github.com/openscad/openscad/issues/6382) to be both more and
less of a problem than I thought, at least on initial investigation.

When you try to use a file that's in a subdirectory with a non-ASCII
name from the command line in a MSYS2 shell, the argument gets mangled. 
This appears to be an issue with the MSYS2 shell/environment mechanism
for path transformation, that makes UNIX-y paths sort of work in a
Windows world, not with OpenSCAD itself.  The same path works fine from
Windows' own CMD, and GUI-based opens seem to be OK.

That's not to say that there aren't problems in this area - I expect
that there are - but as long as you're not in the MSYS2 environment the
situation is better than I feared.

That makes the biggest problem that I know of be the fact that a number
of constructs don't work with non-ASCII file names:

  • include <> of a non-ASCII name
  • use <> of a non-ASCII name
  • surface() of a non-ASCII name

The good news is that these work for the MSYS2 UCRT64 build.  The bad
news is that the "production" OpenSCAD build is an MXE build that uses
the legacy MSVCRT runtime environment.  It is not clear how much work it
is to move the production build over to UCRT64.

Again... those of you who would really rather type your file names in
non-English alphabets, please give it a shot and let me know how it goes.

On 11/20/2025 10:20 AM, Jordan Brown wrote: > It doesn't fix all of them - the biggest remaining is that there are > problems with non-ASCII *directory* names Having gotten that wad of changes off my plate, I looked at the next thing, which is the problem with non-ASCII directory names. That problem turns out (#6382 <https://github.com/openscad/openscad/issues/6382>) to be both more and less of a problem than I thought, at least on initial investigation. When you try to use a file that's in a subdirectory with a non-ASCII name from the command line in a MSYS2 shell, the argument gets mangled.  This appears to be an issue with the MSYS2 shell/environment mechanism for path transformation, that makes UNIX-y paths sort of work in a Windows world, not with OpenSCAD itself.  The same path works fine from Windows' own CMD, and GUI-based opens seem to be OK. That's not to say that there aren't problems in this area - I expect that there are - but as long as you're not in the MSYS2 environment the situation is better than I feared. That makes the biggest problem that I know of be the fact that a number of constructs don't work with non-ASCII file names: * include <> of a non-ASCII name * use <> of a non-ASCII name * surface() of a non-ASCII name The good news is that these work for the MSYS2 UCRT64 build.  The bad news is that the "production" OpenSCAD build is an MXE build that uses the legacy MSVCRT runtime environment.  It is not clear how much work it is to move the production build over to UCRT64. Again... those of you who would really rather type your file names in non-English alphabets, please give it a shot and let me know how it goes.