adding support for multiple taxnomy download#832
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This pull request adds support for downloading GBIF occurrence data using alternative taxonomies (specifically Catalogue of Life XR) by introducing a checklistKey parameter to the pred() function.
Changes:
- Added
checklistKeyparameter topred()function for specifying alternative taxonomies - Added validation to ensure
checklistKeyis only used withtaxonKeypredicates and is a valid UUID - Updated documentation and added vignette section explaining the new functionality
Reviewed changes
Copilot reviewed 17 out of 17 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| DESCRIPTION | Version bump from 3.8.4.4 to 3.8.4.5 |
| R/download_predicate_dsl.R | Added checklistKey parameter to pred() with validation logic |
| man/download_predicate_dsl.Rd | Documentation for new checklistKey parameter |
| man/occ_download.Rd | Clarified verbatim_extensions documentation |
| vignettes/getting_occurrence_data.Rmd | Added section explaining alternative taxonomy downloads |
| tests/testthat/test-occ_download.R | Added tests for checklistKey functionality |
| tests/testthat/test-download_parsing.R | Added test for parse_predicates with checklistKey |
| tests/fixtures/* | Updated test fixtures with new download keys and dates |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
||
| occ_download( | ||
| pred("taxonKey", "Q2M4"), | ||
| checklistKey = "7ddf754f-d193-4cc9-b351-99906754a03b", |
There was a problem hiding this comment.
The checklistKey parameter should be passed to the pred() function, not to occ_download(). The occ_download() function does not have a checklistKey parameter. This code example will fail because occ_download() does not accept checklistKey as a parameter.
Suggested change
| checklistKey = "7ddf754f-d193-4cc9-b351-99906754a03b", | |
| pred("checklistKey", "7ddf754f-d193-4cc9-b351-99906754a03b"), |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#830