IntLatLngSnapFunction.SnapPoint test failure: +/-180 longitude
- Dominant language
- C++
- Stars
- 2.7k
- Forks
- 357
- Avg merge
- 11h 4m
- Merged PRs (30d)
- 1
Description
```
[ RUN ] IntLatLngSnapFunction.SnapPoint
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
E0000 00:00:1777950374.802920 127641 s2latlng.cc:69] Invalid S2LatLng in S2LatLng::ToPoint: [57.1240000, -180.0000000]
E0000 00:00:1777950374.803138 127641 s2latlng.cc:69] Invalid S2LatLng in S2LatLng::ToPoint: [57.1240000, 180.0000000]
/Users/runner/work/s2geometry/s2geometry/src/s2/s2builderutil_snap_functions_test.cc:132: Failure
Expected equality of these values:
p5
Which is: [-0.542823, 1.74585e-16, 0.839847]
IntLatLngSnapFunction(5).SnapPoint(p5)
Which is: [-0.542823, -1.74585e-16, 0.839847]
[ FAILED ] IntLatLngSnapFunction.SnapPoint (15 ms)
```
I see `+ 1` can put it out of range, but we're having problems with `p5` before that.
https://github.com/google/s2geometry/blob/baf4af99fe7a844dd8c42dfe494113cd496b991e/src/s2/s2builderutil_snap_functions_test.cc#L138-L140
Contributor guide
Assessment
This issue has not been assessed yet.