ifcurl/tests
Bruno Postle 65a62ffc8b sandbox.py: subprocess isolation for ifcopenshell parse + render
All ifcopenshell calls (from_string, filter_elements, geom.iterator) now
run inside a short-lived child process via run_sandboxed().  A SIGSEGV or
SIGABRT in the child returns HTTP 422 instead of killing the service worker.
Configurable timeout (IFCURL_SANDBOX_TIMEOUT, default 120s) and optional
resource limits (IFCURL_SANDBOX_MEMORY_MB, IFCURL_SANDBOX_CPU_SECS).

The T3 GUID cache still works: the sandboxed pipeline returns resolved
GUIDs on selector miss so the parent can populate the cache; on hit the
parent passes cached GUIDs and the child converts them to step IDs.

Tests use a sync_sandbox fixture that runs run_sandboxed synchronously so
mock patches remain visible; four dedicated sandbox tests cover normal
return, exception propagation, segfault detection, and timeout.

Closes ifcurl-vm5.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-24 17:38:07 +01:00
..
conftest.py Authentication and test coverage 2026-04-15 23:21:13 +01:00
test_auth.py Authentication and test coverage 2026-04-15 23:21:13 +01:00
test_bcf.py Fix 7 issues from deep review 2026-04-24 11:57:06 +01:00
test_git.py git.py: LRU disk cache eviction; service.py: configurable in-memory limits 2026-04-24 09:06:56 +01:00
test_render.py Authentication and test coverage 2026-04-15 23:21:13 +01:00
test_sandbox.py sandbox.py: subprocess isolation for ifcopenshell parse + render 2026-04-24 17:38:07 +01:00
test_service.py sandbox.py: subprocess isolation for ifcopenshell parse + render 2026-04-24 17:38:07 +01:00
test_url.py Fix port preservation and HTTP fallback for local Gitea 2026-04-15 23:50:54 +01:00
test_viewer_url.mjs viewer: extract URL logic to viewer-url.js, add JS tests 2026-04-24 07:31:19 +01:00