Easy-to-use lock-free atomic integers, booleans, and floats for Python, leveraging C11 atomics. Current version 0.0.15, requires Python >=3.8. Released under MIT license, primarily a single-developer project with infrequent releases.
pip install atomicxVerified import paths — ran on the pinned version, not inferred.
Create and use atomic types with load/store and arithmetic operations.
Use atomic_float.store(atomic_float.load() + 1) or check if .add() is implemented in your version.
Always use .load() to get the value before comparing: if atomic_a.load() == atomic_b.load(): ...
AtomicInt(0) works; AtomicFloat(0.0) works; AtomicFloat(0) may raise TypeError.
Run 'pip install atomicx' to install the package.
Upgrade atomicx: 'pip install --upgrade atomicx'. Or import only available classes: AtomicInt and AtomicBool.
Use .load() to read and .store(value) to write.
No dependency data recorded yet.