Skip to content
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

difficulty loading previous ecodata versions #49

Open
sgaichas opened this issue Apr 12, 2023 · 8 comments
Open

difficulty loading previous ecodata versions #49

sgaichas opened this issue Apr 12, 2023 · 8 comments

Comments

@sgaichas
Copy link
Member

I've tried devtools::install_github("NOAA-EDAB/[email protected]") to get back the commercial engagement indicator from the 2021 report (a time series of med-high and high), but it appears to install the current ecodata when I do this, and the newer version of the indicator is still there (engagement by community).

Entirely likely I'm doing it wrong but here is what I get:

✔  checking for file ‘/private/var/folders/5x/skybg7p1061160n07vnw9cq40000gn/T/RtmpP81H7F/remotes1cad71c22b7f/NOAA-EDAB-ecodata-933e882/DESCRIPTION’ ...
─  preparing ‘ecodata’:
✔  checking DESCRIPTION meta-information ...
─  checking for LF line-endings in source and make files and shell scripts
─  checking for empty or unneeded directories
─  building ‘ecodata_0.1.0.tar.gz’
   
* installing *source* package ‘ecodata’ ...
** using staged installation
** R
** data
*** moving datasets to lazyload DB
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (ecodata)
> library(ecodata)
> eng<-ecodata::engagement %>% 
+   filter(!Var == "med.high.scores")
Error in `filter()`:
! Problem while computing `..1 = !Var == "med.high.scores"`.
Caused by error in `mask$eval_all_filter()`:
! object 'Var' not found
@sgaichas
Copy link
Member Author

It seems to install the same tar.gz when I build current:

> remotes::install_github("NOAA-EDAB/ecodata")
Downloading GitHub repo NOAA-EDAB/ecodata@HEAD
✔  checking for file ‘/private/var/folders/5x/skybg7p1061160n07vnw9cq40000gn/T/RtmpP81H7F/remotes1cad277675b6/NOAA-EDAB-ecodata-cbbff94/DESCRIPTION’ ...
─  preparing ‘ecodata’: (475ms)
✔  checking DESCRIPTION meta-information ...
─  checking for LF line-endings in source and make files and shell scripts
─  checking for empty or unneeded directories
─  building ‘ecodata_0.1.0.tar.gz’
   Warning in utils::tar(filepath, pkgname, compression = compression, compression_level = 9L,  :
     storing paths of more than 100 bytes is not portable:
     ‘ecodata/docs/images/Figure 5_ PSP samples percentage  exceeded the toxicity threshold in Maine 2005-2019 - David Nelson - NOAA Federal.jpg’
   Warning in utils::tar(filepath, pkgname, compression = compression, compression_level = 9L,  :
     storing paths of more than 100 bytes is not portable:
     ‘ecodata/docs/images/Figure 8_PSP samples percentage exceeded the threshold in New Hampshire 2000-2019 - David Nelson - NOAA Federal.jpg’
   Warning in utils::tar(filepath, pkgname, compression = compression, compression_level = 9L,  :
     storing paths of more than 100 bytes is not portable:
     ‘ecodata/docs/images/Figure11_PSP_samples_percentage_exceeding_threshold_in_Massachusetts_1972-2019 - David Nelson - NOAA Federal.jpg’
   Warning in utils::tar(filepath, pkgname, compression = compression, compression_level = 9L,  :
     using GNU extension for long pathname
   
* installing *source* package ‘ecodata’ ...
** using staged installation
** R
** data
*** moving datasets to lazyload DB
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (ecodata)
* ```

@andybeet
Copy link
Member

What you have done should work. not sure why it hasnt.
As a work around you could just download the zip file found on the [release page]
You'd need to create a project copy the files then build it

@kimberly-bastille
Copy link
Member

It looks like the time series version of the engagement indicator was included in the 2020 SOEs (Version 1.1.0).

If that install still doesn't work, the raw data is available here.

@sgaichas
Copy link
Member Author

Bummer, same thing happens when I try 1.1.0. I will do one of the workarounds mentioned above. Thanks @andybeet and @kimberly-bastille

@BBeltz1 BBeltz1 closed this as completed Aug 3, 2023
@slucey slucey reopened this Oct 2, 2023
@slucey
Copy link
Member

slucey commented Oct 2, 2023

Linked to issue #69

@slucey
Copy link
Member

slucey commented Oct 2, 2023

Description file still says version 0.1.0 ... possible with switch to pkgdown this might be fixed.

@andybeet
Copy link
Member

andybeet commented Oct 5, 2023

@sgaichas So i can install v1.1.0 (and other versions) and access the engagement data

devtools::install_github("NOAA-EDAB/[email protected]", force = T)
#> Downloading GitHub repo NOAA-EDAB/[email protected]
#>          checking for file 'C:\Users\andrew.beet\AppData\Local\Temp\2\RtmpAPmDSV\remotes4db05852ec1\NOAA-EDAB-ecodata-2d173f3/DESCRIPTION' ...  ✔  checking for file 'C:\Users\andrew.beet\AppData\Local\Temp\2\RtmpAPmDSV\remotes4db05852ec1\NOAA-EDAB-ecodata-2d173f3/DESCRIPTION'
#>       ─  preparing 'ecodata': (1.3s)
#>    checking DESCRIPTION meta-information ...     checking DESCRIPTION meta-information ...   ✔  checking DESCRIPTION meta-information
#>       ─  checking for LF line-endings in source and make files and shell scripts
#>       ─  checking for empty or unneeded directories
#>       ─  building 'ecodata_0.1.0.tar.gz'
#>      
#> 

Created on 2023-10-05 by the reprex package (v2.0.1)

And i also see that the tarball has the same name for any install (i think this is because the DESCRIPTION file is v0.1.0 for every release, as @slucey noted. We need to update that). This is also why packageVersion("ecodata") always reports v0.1.0

library(magrittr) 
    ecodata::engagement %>% tibble::as_tibble()
#> # A tibble: 150 × 5
#>    EPU    Time Var              Value Units   
#>    <chr> <dbl> <chr>            <dbl> <chr>   
#>  1 NE     2004 %Low            0.801  unitless
#>  2 NE     2004 %Moderate       0.101  unitless
#>  3 NE     2004 %Medium High    0.0461 unitless
#>  4 NE     2004 %High           0.0524 unitless
#>  5 NE     2004 med.high.scores 0.677  unitless
#>  6 NE     2005 %Low            0.782  unitless
#>  7 NE     2005 %Moderate       0.111  unitless
#>  8 NE     2005 %Medium High    0.0587 unitless
#>  9 NE     2005 %High           0.0482 unitless
#> 10 NE     2005 med.high.scores 0.673  unitless
#> # ℹ 140 more rows

Created on 2023-10-05 by the reprex package (v2.0.1)

I did need to restart R after the install. If that doesn't work then you might want to remove.packages("ecodata") and reinstall

We also might want to consider adding a NEWS.md file now too to report changes in package betwen versions

@BBeltz1
Copy link
Collaborator

BBeltz1 commented Nov 7, 2024

@BBeltz1 check that old ecodata can be installed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ToDo
Development

No branches or pull requests

5 participants