google / google/s2geometry

Python S2BuilderTest fails in debug mode

Open
#376 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
2.7k
Forks
357
Avg merge
11h 4m
Merged PRs (30d)
1

Description

I built the v0.11.1 git tag (master failed to build) on Debian trixie with this config:

```
cmake .. -DBUILD_EXAMPLES=OFF -DWITH_PYTHON=ON -DGOOGLETEST_ROOT=/usr/src/googletest
```

The python binding test suite fails with a segfault:

```
$ cd python ; make test
Running tests...
Test project /home/tmx/debian/s2geometry/git-deb-s2geometry/build/python
Start 1: s2geometry_test
1/1 Test #1: s2geometry_test ..................Subprocess aborted***Exception: 3.72 sec

0% tests passed, 1 tests failed out of 1

Total Test time (real) = 3.73 sec

The following tests FAILED:
1 - s2geometry_test (Subprocess aborted)
Errors while running CTest
```

The failing test class is `S2BuilderTest`:

```
$ PYTHONPATH=$(pwd) python3 ../../src/python/s2geometry_test.py S2BuilderTest
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
F0000 00:00:1721660167.483759 916916 s2edge_distances.cc:405] Check failed: tolerance.radians() > 0 (0 vs. 0)
*** Check failure stack trace: ***
Aborted (core dumped)
```

Anything with a call to `S2Builder.AddEdge()` (i.e. all tests in this class) results in a segfault.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.