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
filepaths with umlauts not handled correctly #10507
Comments
Thanks for the bug report! For what it's worth, forcing the strings to be re-encoded as UTF-8 seems to dodge the issue:
I'll see if I can learn more. |
A bunch of people with similar issues in this thread: https://community.rstudio.com/t/rstudio-cant-deal-with-file-names-with-unicode-characters/126601/20 |
A similar issue, with
When run with R-devel + UCRT everything is fine. Unfortunately, with older versions of R, the file name is now mis-encoded.
My suspicion is that this is because RStudio is now compiled to use the Windows UTF-8 code page, but R is still trying to use the "default" system code page. This leads to As far as I can see, the only way to set the application encoding is in the application's manifest file; that is, it must be set at build time, and cannot be changed at run time. https://docs.microsoft.com/en-us/windows/apps/design/globalizing/use-utf8-code-page If this is the case, then I think we need to back out the UTF-8 change for Windows, and later consider distributing two separate builds of RStudio; one for R (>= 4.2.0) and one for R (< 4.2.0). |
Using RStudio Desktop 2022.02.0-431 on Windows 10, I'm still seeing
Is this still supposed to be this way, or should it be UTF-8? |
That's fine; it should still be The most important thing for testing is that
|
In that case, verified fixed. Thanks! |
Will a patched Ghost Orchid version be released as well? |
Just fixed the dailies page! You can get the Windows build here now: https://dailies.rstudio.com/rstudio/ghost-orchid/desktop/windows/2021-09-3-384/ |
Reopening and putting in "test" for Ghost Orchid backport. |
Verified in RStudio Desktop 2021.09.3+396 (Ghost Orchid) with R 3.6.3 and 4.2.0 on Windows 11 using the three repros above: the original post and the two examples by @kevinushey . |
System details
Steps to reproduce the problem
RStudio 2021.09.2+382 and 2022.02.0+421 cause problems with filenames with umlauts, so that tidyverse/non-base packages do not handle them correctly:
Sessioninfo
Code to reproduce
Describe the problem in detail
RStudio Desktop (I tested versions 2021.09.2+382 and 2022.02.0+421) apparently handles filenames/-paths with umlauts/non-ASCII characters differently than previous versions. As a result, some non-base packages cannot handle the paths correctly. The problem does not occur in the R console, when run with {reprex} from RStudio, or with RStudio 2021.09.0+351, which is why I think that this is a regression in RStudio. I have used multiple packages to show that this is not isolated to one of them.
The issue also does not occur with R devel (2022-02-03 r81650 ucrt) - but that is not released yet and I assume that RStudio is supposed to work with R < v4.2 for a little longer?
Describe the behavior you expected
RStudio and non-base packages work well together, so that file-paths with non-ASCII characters do not cause errors.
The text was updated successfully, but these errors were encountered: