Skip to content

Commit 4fc4504

Browse files
committed
Bump version to 1.3.0, document C code optimizations
1 parent 4941f85 commit 4fc4504

2 files changed

Lines changed: 16 additions & 2 deletions

File tree

CHANGELOG.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Changelog
22

3-
## 1.2.1 (2026-02-16)
3+
## 1.3.0 (2026-02-16)
44

55
### Added
66

@@ -22,6 +22,20 @@
2222
`nif_resume_callback_dirty` now uses flag-based detection (checking `tl_pending_callback`)
2323
instead of exception-type detection.
2424

25+
### Changed
26+
27+
- **C code optimizations and refactoring**
28+
- **Thread safety fixes**: Used `pthread_once` for async callback initialization,
29+
fixed mutex held during Python calls in async event loop thread
30+
- **Timeout handling**: Added `read_with_timeout()` and `read_length_prefixed_data()`
31+
helpers with proper timeouts on all blocking pipe reads (30s for callbacks, 10s for spawns)
32+
- **Code deduplication**: Merged `create_suspended_state()` and
33+
`create_suspended_state_from_existing()` into unified `create_suspended_state_ex()`,
34+
extracted `build_pending_callback_exc_args()` and `build_suspended_result()` helpers
35+
- **Performance**: Optimized list conversion using `enif_make_list_cell()` to build
36+
lists directly without temporary array allocation
37+
- Removed unused `make_suspended_term()` function
38+
2539
## 1.2.0 (2026-02-15)
2640

2741
### Added

src/erlang_python.app.src

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{application, erlang_python, [
22
{description, "Execute Python applications from Erlang using dirty NIFs"},
3-
{vsn, "1.2.0"},
3+
{vsn, "1.3.0"},
44
{registered, [py_pool]},
55
{mod, {erlang_python_app, []}},
66
{applications, [

0 commit comments

Comments
 (0)