Skip to content

test_embed Fatal error for IO Safety violation #681

@Noahnut

Description

@Noahnut

Description

When running the unit test test_embed.py, the process aborts with the following error:

Fatal runtime error: IO Safety violation: owned file descriptor already closed, aborting
Fatal Python error: Aborted

The crash looks like it is triggered during shutdown / worker stopping logic in the Rust side.
From debugging, it seems there may be a duplicate Stopping worker call, which could result in the same file descriptor being closed twice (violating Rust’s IO safety guarantees).

Steps to Reproduce

Create a virtual environment with Python 3.13

Install project dependencies

Run:

pytest -vv tests/test_embed.py

Observer

Crash with fatal runtime error: IO Safety violation: owned file descriptor already closed, aborting Fatal Python error: Aborted

Screenshot

Image

If possible, I would like to try fixing this issue. Thank you.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions