-4

I'm writing a Shiny app in RStudio Server v. 1.1.442 on R 3.4.4, and today when I opened my ui.R file to edit, any edits I make are met with the popup error "R code execution error" and repeated printing of

Error in object[[3]] : subscript out of bounds

to the console, when I'm not even executing any code. Code suggestions are completely gone while editing.

I tried closing the project and opening the files individually in a new project, but that changed nothing. I feel like it's probably an error in one of the packages I use in this project, but I have no idea how to diagnose it. Any help will be very appreciated!

Here's a list of packages I'm using:

shiny, DT, shinyMCE, wordcloud, stringr, ngram, shinyjs, rvest, RCurl, XML, stringi, magrittr, data.table, phrasemachine, urltools, textclean

Artem
  • 3,304
  • 3
  • 18
  • 41
Nathan
  • 97
  • 2
  • 9

1 Answers1

0

It may be connected with RStudio code autocompletion specifics of dealing with magrittr/dplyr libraries' pipe operator %>%, especially when it is nested or joins involved. It may generate this kind of error however it depends on Windows version as well. Try to substitute piping to direct function call.

Please check the issue Code Completion Error

Artem
  • 3,304
  • 3
  • 18
  • 41