-
Notifications
You must be signed in to change notification settings - Fork 4
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
Add geotargets options functions, with defaults for raster GDAL driver and creation options #19
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks so much for these changes, @brownag ! This is awesome.
Just a couple of suggestions regarding abstracting out some parts into functions - let me know if you would prefer not to do these?
I also think we will want to import rlang
- it's already in targets
so we aren't adding a dependency, and I think we could benefit from some rlang functions, such as %||%
.
Also thank you so much for catching that {covr} error - I had just chalked it up to "CI be weird sometimes" and shelved it for later. This is a huge help! |
- use `%||%` and `arg_match0() `in `tar_terra_rast()`
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few ideas/suggestions and a request to get an error if you ask to set/get an invalid option name.
Two new draft functions were added for #16 :
geotargets_option_get()
andgeotargets_option_set()
.I noticed that the code coverage was failing. There seems to be an issue with modifying the function body for
create_format_terra_raster()
insidecovr::package_coverage()
. This PR fixes that.It appears coverage issue can be resolved by allowing for the default options for GDAL driver (
filetype
) and creation options (gdal
) to be used in the template function, rather thanNULL
. Though I am still curious what is happening inside the evaluation {covr} does that causes this to fail.