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

10855_change_precision_of_incoming_geoms #10922

Merged
merged 12 commits into from
May 16, 2024

Conversation

ryan86
Copy link
Contributor

@ryan86 ryan86 commented May 14, 2024

  • Make precision reduction function recursive
  • Separate bbox and precision/byte size validation
  • Add tests

@ryan86 ryan86 requested a review from chiatt May 14, 2024 18:36
@jacobtylerwalls
Copy link
Member

@ryan86 The webpack failure should be resolved in a few minutes, once I merge #10776

Copy link
Member

@jacobtylerwalls jacobtylerwalls left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just swung by to see if webpack was happier, noticed a couple things esp. in the tests.

tests/utils/datatype_tests.py Outdated Show resolved Hide resolved
tests/utils/datatype_tests.py Outdated Show resolved Hide resolved
arches/app/datatypes/datatypes.py Outdated Show resolved Hide resolved
tests/utils/datatype_tests.py Outdated Show resolved Hide resolved
current_precision = abs(self.find_num(feature_geom.coords))

geom = geo_utils.reduce_precision(geom, current_precision)
except:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be good to name the error that is being excepted here. That would clarify the code and prevent excepting any unexpected errors.

arches/app/datatypes/datatypes.py Outdated Show resolved Hide resolved
arches/app/datatypes/datatypes.py Outdated Show resolved Hide resolved
arches/app/datatypes/datatypes.py Outdated Show resolved Hide resolved
arches/app/datatypes/datatypes.py Outdated Show resolved Hide resolved
arches/app/utils/geo_utils.py Outdated Show resolved Hide resolved
arches/app/utils/geo_utils.py Outdated Show resolved Hide resolved
tests/utils/datatype_tests.py Outdated Show resolved Hide resolved
@ryan86 ryan86 requested a review from chiatt May 15, 2024 22:02
@chiatt chiatt merged commit 7d1858b into dev/7.6.x May 16, 2024
7 checks passed
@chiatt chiatt deleted the 10855_change_precision_of_incoming_geoms branch May 16, 2024 01:41
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.

None yet

3 participants