-
Notifications
You must be signed in to change notification settings - Fork 20
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
special characters in file path #82
Comments
I can't reproduce this error on my Linux device, or in Windows via GitHub Actions. The code that unzips the file is in https://github.com/nacnudus/tidyxl/blob/main/R/zip.R. Please could you try running similar code, to see where the error happens? |
Unzipping the file with your code works fine. So the problem seems to be elsewhere. I debugged a bit and found out the error mesage occurs in Also note the code of my first message ran successfully on another computer of mine which is Windows too... |
Hello again. I'm not giving up on this one. 😉 I think I managed to make the problem reproducible. Apparently the bug happens when the paht is encoded in UTF-8. Here is the updated MRE : library(tidyxl)
examples <- system.file("extdata/examples.xlsx", package = "tidyxl")
path_with_special_char <- file.path(tempdir(), "é")
# update here : convert to UTF-8
path_with_special_char <- iconv(path_with_special_char, "latin1", "UTF-8")
dir.create(path_with_special_char)
file.copy(examples, path_with_special_char)
xlsx_cells(file.path(path_with_special_char, "examples.xlsx")) |
Hello,
xlsx_cells
is not able to read a file when there are special characters (as "é" in french) in its path.Here is a reproducible example :
I run this on Window. My sessionInfo :
The text was updated successfully, but these errors were encountered: