rstudio / packrat

Packrat is a dependency management system for R
http://rstudio.github.io/packrat/
401 stars 89 forks source link

Found continuation line starting ... #470

Open bogdanrau opened 6 years ago

bogdanrau commented 6 years ago

Issue linked to https://github.com/jbkunst/highcharter/issues/429. When running packrat::init(), all packages get installed fine (even some installed with devtools::install_github), with the exception of the highcharter package. Some key facts below:

  1. packrat::init() works if highcharter is installed either from CRAN, or from source (CRAN or github).
  2. It does not work if installing directly from github (ie. devtools::install_github('jbkunst/highcharter').
  3. This bug is NOT present in version 0.4.8-1, but is present in the current version. I've confirmed this by running packrat::init() using both 0.4.8-1 and 0.4.9-2 and getting the error only when running it under 0.4.9-2.
Error in read.dcf(...) : 
  Found continuation line starting '    shortcut functio ...' at begin of record.
kevinushey commented 6 years ago

I just attempted a packrat::init() using the development version of highcharter and it worked fine. Can you provide more information on what version of R + OS you're using?

Does the following work on your machine?

read.dcf(system.file("DESCRIPTION", package = "highcharter"))
superchordate commented 5 years ago

Might be related to https://github.com/r-lib/devtools/issues/1900. Possible workaround is using package githubinstall instead of devtools to install from github.

vishalsharma3003 commented 1 year ago

This error occurs when the packrat is not able to read the DESCRIPTION file for the package. First you need to identify which package is causing the issue and you can check that by reading the logs file. As there is not much information in the error then I suppose it's the highchartr package which is causing the issue here. The issue says that there was a continuation line found in the DESCRIPTION file. You can navigate to the DESCRIPTION file by locating the package at one of your .libPaths(). Open the DESCRIPTION file and remove the blank line added in it and retry installing the version. It worked fine for me. The same error occurred for me during the deployment to RStudio Connect as it does the same thing i.e., packrat::restore().

aronatkins commented 1 year ago

@vishalsharma3003 A reprex would be very helpful.

The links to devtools / remotes issues like https://github.com/r-lib/devtools/issues/709, https://github.com/r-lib/devtools/issues/1900, and https://github.com/r-lib/remotes/issues/248 are situations where other tools incorrectly created DESCRIPTION files.

Are you able to demonstrate how the "bad" DESCRIPTION file is getting created? How was that package installed?