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

bcdc_query_geodata error #121

Closed
ebambrick opened this issue Oct 29, 2019 · 3 comments · Fixed by #122
Closed

bcdc_query_geodata error #121

ebambrick opened this issue Oct 29, 2019 · 3 comments · Fixed by #122

Comments

@ebambrick
Copy link

Hi,
I have been using the bcdata package for a while now and it's awesome!!
I regularly retrieve a filtered version of the forest tenure harvest authority polygons data, but this week an error message is returned:

DMK_harv_authority <- bcdc_query_geodata('cff7b8f7-6897-444f-8c53-4bb93c7e9f8b') %>%
filter(GEOGRAPHIC_DISTRICT_CODE == "DMK") %>%
collect()

Error: Can't find columns name, type in .data.`

I also tried to download the entire dataset (not ideal because it's so big):

prov_harv_auth <- bcdc_get_data(record = 'cff7b8f7-6897-444f-8c53-4bb93c7e9f8b', resource = 'b66b136e-433b-474e-a33c-3c31fd7e0c02')'

And the same error was returned along with some warnings (this code was copied directly from the bcdc_get_record('cff7b8f7-6897-444f-8c53-4bb93c7e9f8b') output):

Error: Can't find columns name, type in .data.
Call rlang::last_error() to see a backtrace.
In addition: Warning messages:
1: In xpath_search(x$node, x$doc, xpath = xpath, nsMap = ns, num_results = Inf) :
Undefined namespace prefix [1219]
2: Unknown or uninitialised column: 'type'.
3: Unknown or uninitialised column: 'nillable'.

I checked the data bc webpage (https://catalogue.data.gov.bc.ca/dataset/forest-tenure-harvesting-authority-polygons) and noticed that the wms download returns a 404 error rather than an xml as would be expected. Maybe related?

Any help would be appreciated!!
Thanks!

@boshek
Copy link
Collaborator

boshek commented Oct 29, 2019

👋 @ebambrick

Thanks for the report. Your usage of bcdata is correct and nothing has changed with the package. Rather this is an issue with data in the catalogue. It has been reported though I do not have any timeline when this particular WFS record will be available again.

@ateucher
Copy link
Collaborator

My thanks as well @ebambrick - @boshek we should catch these 404 errors more elegantly.

@ebambrick
Copy link
Author

Thanks!
I'll close this issue and wait for it to be resolved at data bc.

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

Successfully merging a pull request may close this issue.

3 participants