ropensci / rnaturalearth

An R package to hold and facilitate interaction with natural earth map data :earth_africa:
http://ropensci.github.io/rnaturalearth/
Other
214 stars 24 forks source link

link between rnaturalearth and rnaturalearthdata pre CRAN submission #14

Closed andysouth closed 6 years ago

andysouth commented 7 years ago

@sckott Finally found time to try to submit rnaturalearth to CRAN (apologies for delay).

Just to remind you. The plan recommended by Lincoln Mullen was :

rnaturalearth CRAN rnaturalearthdata CRAN rnaturalearthhires rOpenSci drat repo (already there)

Because I want to submit rnaturalearth & rnaturalearthdata together I get no errors & warnings locally, but when submitting to win-builder I get. 4 ERRORs, 1 WARNING, 3 NOTEs e.g. The rnaturalearthdata package needs to be installed. Error in install_rnaturalearthdata() : Failed to install the rnaturalearthdata package.

https://win-builder.r-project.org/DXH5l7715FOc/00check.log

Can you suggest how best to fix ?

sckott commented 7 years ago

@AndySouth I'll have a look

sckott commented 7 years ago

do you check locally with --as-cran ?

sckott commented 7 years ago

I think you need to submit rnaturalearthdata to CRAN first - then submit rnaturalearth - what do you mean by

submit rnaturalearth & rnaturalearthdata together

andysouth commented 7 years ago

Thanks @sckott I hadn't thought to submit rnaturalearthdata to CRAN first, I'll do that.

Can you activate, or enable me to activate rnaturalearthdata on travis ?

It's telling me I don't have admin rights.

sckott commented 7 years ago

@AndySouth Okay, travis is now on for that pkg, let me know if you need anything else

sckott commented 7 years ago

@AndySouth you're now admin on both repos

andysouth commented 7 years ago

Thanks @sckott rnaturalearthdata now succesfully on CRAN (hurrah!)

Ready to submit rnaturalearth, it passes locally and on travis but when I submit to winbuilder it fails due to installation of rnaturalearthhires.

Would you recommend submitting to cran anyway ?

winbuilder error below : and here

** running examples for arch 'i386' ... ERROR
Running examples in 'rnaturalearth-Ex.R' failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: ne_states
> ### Title: Get natural earth world state (admin level 1) polygons
> ### Aliases: ne_states ne_admin1
> 
> ### ** Examples
> 
> 
> # comparing using country and geounit to filter
> spdf_france_country <- ne_states(country = 'france')
The rnaturalearthhires package needs to be installed.
Installing the rnaturalearthhires package.
Installing package into 'D:/temp/RtmpGaDuTO/RLIBS_48c421ae5c10'
(as 'lib' is unspecified)
Error in value[[3L]](cond) : 
  Failed to install the rnaturalearthhires package.
sckott commented 7 years ago

Awesome it's on CRAN now.

Not sure, I'll have a look

sckott commented 7 years ago

rnaturalearth should pass check without packages in Suggests available - which sounds like that's not the case?

Examples in your pkg that need rnaturalearthdata or rnaturalearthhires need to be wrapped in

if (requireNamespace("ourpackage")) {
  # examples stuff
}

so examples then only run if that pkg is available