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

Pass tests on Apple silicon #951

Closed
jchamberlain opened this issue Sep 11, 2023 · 1 comment
Closed

Pass tests on Apple silicon #951

jchamberlain opened this issue Sep 11, 2023 · 1 comment

Comments

@jchamberlain
Copy link
Contributor

jchamberlain commented Sep 11, 2023

Tegola's tests don't pass on M1/M2 Macs for two reasons:

  1. Many calculated floats are slightly (insignificantly) different, but SQL string comparisons in the PostGIS and Hana providers expect an exact match.
  2. TestGenerateTilesForBounds fails because of a bug in go-spatial/geom (uint overflow, resulting in implementation-specific behavior—see cmd/compile: casting a negative float to uint64 has different behavior on arm64 and amd64 golang/go#52943). The geom code in question has since been rewritten and does not exhibit the same bug, so upgrading fixes it.

From my perspective, (2) is best fixed by upgrading go-spatial/geom. But that introduces its own trouble in that some float calculations are even more different (exacerbating 1), and backward-incompatible changes have been made.

@jchamberlain
Copy link
Contributor Author

With the two PRs merged, tests are now passing on my M1 Mac. Thank you!

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

1 participant