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

rems cache removed when downloading historic #62

Closed
steffilazerte opened this issue Apr 13, 2021 · 4 comments · Fixed by #63
Closed

rems cache removed when downloading historic #62

steffilazerte opened this issue Apr 13, 2021 · 4 comments · Fixed by #63
Labels

Comments

@steffilazerte
Copy link
Contributor

Sorry for the separate issues (I think they're different problems).

In #61 I mentioned that sometimes my rems cache gets removed. I'm not sure if this is meant to happen, but it looks like if the rems cache directory exists, the entire folder is removed when updating historic data... but presumably that isn't meant to happen?

This also removed recent data, and means that my historical data update fails because there's no rems cache folder anymore

rems/R/ems_sqlite.R

Lines 67 to 70 in 9d228b7

if (db_exists) {
unlink(dirname(db_path), recursive = TRUE)
write_db_path()
}

Presumably, if the rems cache folder isn't deleted, then my other issue #61 is much less relevant...

Is there something I'm missing?

@ateucher
Copy link
Contributor

I think you're on to something! I'll have a look

@ateucher
Copy link
Contributor

@steffilazerte would you mind testing? You can install from the fix-historic-removal branch.

@steffilazerte
Copy link
Contributor Author

Will do, but probably tomorrow!

@steffilazerte
Copy link
Contributor Author

Tested updating existing recent and historical, as well as downloading fresh recent and historical and the cache updated with no problems!. Thanks!

ateucher added a commit that referenced this issue Apr 14, 2021
put historic db in subfolder, only remove db file. Fixes #62
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants