-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Function definition in Sweave-file causes error in RStudio #14646
Comments
@protonenfalter Thank you for raising the issue! I'm seeing similar issues when pasting in a Sweave file, on Windows 11 with RStudio Desktop 2024.04.0+735, but it works in 2023.12.1+402. This includes not being able to close files, and sometimes I can't close RStudio--I need to use the task manager. I tried a few other file types, but haven't found any others with a similar issue. |
Indeed. This seems to be a regression. On my platforms RStudio 2023.12.1+402 also works fine with the example given above. |
I can confirm that this issue also exists on MacOS 14.4.1 |
@brry has a minimal example of creating a file with the following code, and then trying to open the file. The brackets are the offenders.
|
Descargue la versión RStudio-2024.04.1-748 y sigue el mismo problema de los {} en rsweave. Alguien sabe cuando se arreglará? |
@jssanhueza Aún no tenemos una solución para esto, pero estamos trabajando en ello. Lamentablemente todavía no tengo un horario para ello. (I used Google Translate. Original: We don't have a solution for this yet, but we are working on it. Unfortunately I don't have a schedule for it yet.) |
Ref: Support ticket 105091. |
Seen in support ticket 105231, which mentions an SO question: https://stackoverflow.com/questions/78415043/cannnot-open-rnw-file-after-r-update-to-4-4-0-typeerror-cannot-read-propert/78486931#78486931 |
This is fixed in the latest dailies of the release that we're currently working on. You can get a daily build from https://dailies.rstudio.com/ if you'd like to checking it out. Please note that the dailies are meant for testing purposes only, not production. |
QA note: Verified in RStudio Desktop 2024.07.0-daily+133 on Windows 11. |
Seen in ticket ZD # 105499 |
Update: We have a fix for this in an upcoming patch. You can get a development version of patch 2024.04.2 at https://dailies.rstudio.com/rstudio/chocolate-cosmos/. Please note that these builds are for testing purposes only, not production. |
Verified in RStudio Desktop 2024.04.2+761 on Windows 11. See automated tests: https://github.com/rstudio/rstudio-ide-automation/pull/1949 |
Verified in RStudio Desktop 2024.07.0-daily+174 on Windows 11 using the same tests. |
Verify fixed in:
System details
Steps to reproduce the problem
Save this minimal example as 'test.rnw' and open the file in RStudio:
simpletest.txt
Alternatively paste the text in a new empty file in RStudio and save the file as 'test.rnw'.
IMPORTANT: There is no issue if the file is opened / edited as ordinary .txt file! Only if the file is designated as of type Sweave (file ending .rnw) the described problems occur!
Describe the problem in detail
When opening the file RStudio throws an error:
(Type Error): Cannot read properties of undefined (reading 'count')
No file is opened.
When saving the text example as .rnw, the file viewer shows garbage / blank space and the file can no longer be edited.
NOTE: With larger Sweave-files containing similar function definitions, RStudio might completely crash!
Describe the behavior you expected
File should open/save properly and can be further worked on.
The text was updated successfully, but these errors were encountered: