Skip to content

tests: add OGC self-touch crash case#79

Merged
NailxSharipov merged 1 commit into
iShape-Rust:mainfrom
Filyus:ogc-crash-regression-test
Jun 18, 2026
Merged

tests: add OGC self-touch crash case#79
NailxSharipov merged 1 commit into
iShape-Rust:mainfrom
Filyus:ogc-crash-regression-test

Conversation

@Filyus

@Filyus Filyus commented Jun 18, 2026

Copy link
Copy Markdown

This PR adds a minimized regression test for the OGC extraction crash discussed in #78.

It intentionally contains only the test case, without a proposed fix, following the maintainer request in the previous PR thread.

Observed on current main:

  • cargo test --test crash_tests test_05 -- --nocapture fails with assertion failed: overlay_rule.is_fill_top(link.fill) in extract_ogc.rs.
  • cargo test --release --test crash_tests test_05 -- --nocapture fails with index out of bounds: the len is 40 but the index is 9223372036854775807.

The input is the minimized 4-contour / 13-point case from the standalone reproducer.

@Filyus

Filyus commented Jun 18, 2026

Copy link
Copy Markdown
Author

For reference, I pushed a separate fix branch here:

https://github.com/Filyus/iOverlay/tree/ogc-start-edge-contours

That branch applies the start-edge end marker fix discussed above, scoped to OGC contour extraction: once traversal reaches the contour start node, it allows the already visited start link to be selected as the contour end marker, instead of treating the node itself as the end detector. Locally it passes:

  • cargo test --test crash_tests test_05 -- --nocapture
  • cargo test --test ocg_tests
  • cargo test

Small note: the fix branch was developed with LLM assistance.

@NailxSharipov NailxSharipov merged commit 4f92dc5 into iShape-Rust:main Jun 18, 2026
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.

2 participants