This release adds 1 notable feature for engineering teams evaluating rollout.
✓ No known CVEs patched in this version
Topics
+10 more
Summary
AI summaryFixes a memory leak in Task.init() by cleaning up temporary ChatDocument instances.
Full changelog
Python 3.13 support and Task.init() memory leak fix
Python 3.13 support
PR [#1011](https://github.com/langroid/langroid/pull/1011) bumps the supported Python range to >=3.10,<3.14 and adds Python 3.13 to the CI matrix alongside 3.11, so Langroid is now tested on both versions on every push.
pyproject.toml:requires-python = "<3.14,>=3.10".github/workflows/validate.yml: lint/test job now runs against["3.11", "3.13"]
Fix ObjectRegistry memory leak in Task.init()
PR [#1022](https://github.com/langroid/langroid/pull/1022) (originally [#1021](https://github.com/langroid/langroid/pull/1021)) fixes a memory leak in Task.init(). The method built a temporary ChatDocument solely to feed log_message(Entity.SYSTEM, ...), but ChatDocument.__init__ auto-registers every instance in the class-level ObjectRegistry, so each new Task left behind a system-message doc that was never freed. In long-running services that spawn many tasks (e.g. servers), this accumulated significantly over time.
The fix:
- explicitly removes the temporary doc via
ChatDocument.delete_id(...)after logging - renames the local to
system_message_temp_docto make its transient nature obvious - adds a regression test (
test_task_init_no_registry_leak) mirroring the PR #939 leak-check pattern, asserting that repeatedTask(...).init()calls leave zero leakedChatDocuments in the registry
Thanks to @alexagr for the catch and the original fix.
Weekly OSS security release digest.
The CVE patches and breaking changes that affected production tools this week. One email, every Sunday.
No spam, unsubscribe anytime.
Share this release
Related context
Related tools
Beta — feedback welcome: [email protected]