Repository navigation
Conversation
…iver_version cy_driver_version() filled a module-level tuple without synchronization. On free-threaded builds, concurrent first calls could replace the tuple while another thread was reading it, leaking it or releasing it too often. driver_version() is already cached with functools.cache, which is safe under concurrent calls, so cy_driver_version() now returns it directly.
|
/ok to test f540a59 |
|
No actionable comments were generated in the recent review. Summary
Change: Bug fix Merge Risk:
|
|
Description
cy_driver_version()filled a module-level cache without synchronization, so on free-threaded builds, concurrent first calls could leak or over-release the cached tuple.driver_version()is already cached withfunctools.cache, which is thread-safe, socy_driver_version()now returns it directly. Callers are unchanged.The race needs a free-threaded build and several threads making their first version-gated call at the same moment, so there is no issue, release note, or new test. Found while reviewing #3516.
Checklist