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

map_tuples() outputs GeoJSON object with identical properties as input GeoJSON object #216

Closed
wants to merge 2 commits into from

Conversation

Stoops-ML
Copy link

@Stoops-ML Stoops-ML commented Jun 19, 2023

This fixes #136.

Changes applied to utils.map_geometries() and utils.map_tuples():

  1. outputs GeoJSON object instead of dictionary
  2. outputted GeoJSON object has the same properties as inputted GeoJSON object

A test has been added at test_utils.TestMapTuples().

@rayrrr
Copy link
Member

rayrrr commented Nov 1, 2023

Hi @Stoops-ML thanks for this, but my understanding of utils.map_geometries() and utils.map_tuples() is that they are intended to return generic Python objects, not GeoJSON objects. If you look in the docstrings, rtype of map_tuples() is list, for example, not GeoJSON object. I can't think of a clean way to make this suggested change without violating the Chesterton's Fence principle.

@rayrrr rayrrr closed this Nov 1, 2023
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 this pull request may close these issues.

Map_Coords/(Other Map_* operations) loses data and affects original referenced object
2 participants