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

Transformer.from_crs() got an unexpected keyword argument 'skip_equivalent' #15

Closed
simonw opened this issue Jan 8, 2023 · 2 comments
Closed
Labels
bug Something isn't working

Comments

@simonw
Copy link
Owner

simonw commented Jan 8, 2023

Getting this error:

zip://timezones-with-oceans.shapefile.zip
  [------------------------------------]    0%
Traceback (most recent call last):
  File "/Users/simon/.local/share/virtualenvs/timezones-api-Lb_JnQTU/bin/shapefile-to-sqlite", line 8, in <module>
    sys.exit(cli())
  File "/Users/simon/.local/share/virtualenvs/timezones-api-Lb_JnQTU/lib/python3.10/site-packages/click/core.py", line 1130, in __call__
    return self.main(*args, **kwargs)
  File "/Users/simon/.local/share/virtualenvs/timezones-api-Lb_JnQTU/lib/python3.10/site-packages/click/core.py", line 1055, in main
    rv = self.invoke(ctx)
  File "/Users/simon/.local/share/virtualenvs/timezones-api-Lb_JnQTU/lib/python3.10/site-packages/click/core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Users/simon/.local/share/virtualenvs/timezones-api-Lb_JnQTU/lib/python3.10/site-packages/click/core.py", line 760, in invoke
    return __callback(*args, **kwargs)
  File "/Users/simon/.local/share/virtualenvs/timezones-api-Lb_JnQTU/lib/python3.10/site-packages/shapefile_to_sqlite/cli.py", line 105, in cli
    db_table = utils.import_features(
  File "/Users/simon/.local/share/virtualenvs/timezones-api-Lb_JnQTU/lib/python3.10/site-packages/shapefile_to_sqlite/utils.py", line 50, in import_features
    transformer = Transformer.from_crs(
TypeError: Transformer.from_crs() got an unexpected keyword argument 'skip_equivalent'
@simonw simonw added the bug Something isn't working label Jan 8, 2023
@simonw
Copy link
Owner Author

simonw commented Jan 8, 2023

https://pyproj4.github.io/pyproj/stable/history.html#id2 says that in pyproj 3.4.0:

  • CLN: Remove deprecated skip_equivalent kwarg from transformers and errcheck kwarg from CRS.from_cf() (pull #1077)

@simonw
Copy link
Owner Author

simonw commented Jan 8, 2023

Ran pip install -U pyproj in my local environment and now I can see this error locally too (previously I had pyproj-2.6.1.post1).

pytest now says:

=== short test summary info ===
FAILED tests/test_shapefile_to_sqlite.py::test_import_features[None] - TypeError: from_crs() got an unexpected keyword argument 'skip_equivalent'
FAILED tests/test_shapefile_to_sqlite.py::test_import_features[customtable] - TypeError: from_crs() got an unexpected keyword argument 'skip_equivalent'
FAILED tests/test_shapefile_to_sqlite.py::test_import_features_spatialite - TypeError: from_crs() got an unexpected keyword argument 'skip_equivalent'
FAILED tests/test_shapefile_to_sqlite.py::test_import_features_spatialite_with_custom_crs - TypeError: from_crs() got an unexpected keyword argument 'skip_...
FAILED tests/test_shapefile_to_sqlite.py::test_import_features_spatial_index - TypeError: from_crs() got an unexpected keyword argument 'skip_equivalent'
FAILED tests/test_shapefile_to_sqlite.py::test_import_features_extract_columns - TypeError: from_crs() got an unexpected keyword argument 'skip_equivalent'
FAILED tests/test_shapefile_to_sqlite.py::test_import_features_extract_columns_spatialite - TypeError: from_crs() got an unexpected keyword argument 'skip_...
=== 7 failed, 1 passed in 2.40s ===

simonw added a commit that referenced this issue Jan 8, 2023
simonw added a commit that referenced this issue Jan 8, 2023
simonw added a commit that referenced this issue Jan 8, 2023
@simonw simonw closed this as completed Jan 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant