luisDVA / annotater

Annotate Package Load Calls
https://annotater.liomys.mx/
Other
99 stars 2 forks source link

not working on latest Rstudio (Version 1.4.1717) #9

Closed verajosemanuel closed 3 years ago

verajosemanuel commented 3 years ago

using previous version everything was ok. Then upgraded to Version 1.4.1717 and error message window arises:

Screenshot 2021-06-08 110704

luisDVA commented 3 years ago

Thanks for bringing this up. Other than that pop-up window are you getting an error message in the console?

The only way I can recreate that message in the latest RStudio is by running functions from the addin menu with the focus on the console rather than the open script.

If this is the case, this is normal. Let me know if this helps. LD

verajosemanuel commented 3 years ago

opening an R file and calling from console:

annotater::annotate_active_file()
Error in annotater::annotate_active_file() : 
  Focus (blinking cursor) is not on an open R file
Run `rlang::last_error()` to see where the error occurred.

annotater::annotate_pkg_calls()
Error in match_pkg_names(string_og) : 
  argument "string_og" is missing, with no default
luisDVA commented 3 years ago

I've looked into this, and with R v 4.1.0 and RStudio 1.4.17 all the addins work correctly when used in an active file. At this point, only annotate_script is meant for running from the console, so I'll make sure to update the documentation to state this explicitly. Thanks again!