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

TypeError : cell_to_boundary() got an unexpected keyword argument 'geo_json' #380

Open
tomrussell-willdan opened this issue Jun 13, 2024 · 4 comments

Comments

@tomrussell-willdan
Copy link

cell_to_boundary() not accepting direct assingment of arguement for unpacking.
image

@ajfriend
Copy link
Contributor

Could you give an example of the behavior you're expecting?

Also, this is for v3.7. You may want to try the new v4.0: pip install h3 --pre

@tomrussell-willdan
Copy link
Author

when I use the function I try to pass it explicitly the assignment of a value to the geo_json argurment but it does not like when i do that. the example is

What I expect to do:

useGeoJsonFormat = True
cell_value = '827507fffffffff'
h3.cell_to_boundary(cell_value, geo_json=useGeoJsonFormat)

This thows the error in the title

What I end up having to do that works and is a work around

useGeoJsonFormat = True
cell_value = '827507fffffffff'
h3.cell_to_boundary(cell_value, useGeoJsonFormat)

@dfellis
Copy link
Collaborator

dfellis commented Jun 13, 2024

Looking through the source code, myself, I'm not sure that geo_json flag still exists?

EDIT: I don't see it in the Cython, either, though I didn't expect it there; more that it'd be at a higher level restructuring it's output.

EDIT2: I did a local check of the repo and there's only one place where the string geo_json exists in the 4.0 beta:

damocles@talyn:~/oss/h3-py(master)$ git grep geo_json
tests/polyfill/test_h3.py:def test_polyfill_geo_json_compliant():

So I think this feature was accidentally dropped during the rewrite for H3 4.0 vs 3.x. @tomrussell-willdan I would say if you need this feature, at the moment you should use h3-py's 3.7.x release, calling h3_to_geo_boundary and @ajfriend can either update the docs to drop this flag, or update the beta to restore this feature.

@tomrussell-willdan
Copy link
Author

thanks. I think for now we will stick on 4.0 and just flip the output ourselves. So is the plan to continue having arguements for geo_json conformity and it was just accidently not included or is the plan to not continue supporting it those arguements?

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

No branches or pull requests

3 participants