devel/py-greenlet 3.5.5 NetBSD
Lightweight in-process concurrent programming
- System
- NetBSD
- Repository
- pkgsrc
- Maintainer
- [email protected]
- Last update
- Commit
2781072caa- License
- mit
- Categories
- devel, python
- Package size
- 243.8 KiB, 1355.6 KiB installed
Description
The greenlet package is a spin-off of Stackless, a version of CPython that supports micro-threads called "tasklets". Tasklets run pseudo-concurrently (typically in a single or a few OS-level threads) and are synchronized with data exchanges on "channels".
A "greenlet", on the other hand, is a still more primitive notion of micro-thread with no implicit scheduling; coroutines, in other words. This is useful when you want to control exactly when your code runs. You can build custom scheduled micro-threads on top of greenlet; however, it seems that greenlets are useful on their own as a way to make advanced control flow structures. For example, we can recreate generators; the difference with Python's own generators is that our generators can call nested functions and the nested functions can yield values too. Additionally, you don't need a "yield" keyword. See the example in tests/test_generator.py.
Greenlets are provided as a C extension module for the regular unmodified interpreter.
Greenlets are lightweight coroutines for in-process concurrent programming.
In the other systems
| System | Port | Version |
|---|---|---|
| NetBSD | devel/py-greenlet | 3.5.5 |
| FreeBSD | devel/py-greenlet | 3.5.6 |
| OpenBSD | devel/py-greenlet | 3.5.6 |
| DragonFly | devel/py-greenlet | 3.1.1 |
| MidnightBSD | devel/py-greenlet | 3.3.0_1 |
| HardenedBSD | devel/py-greenlet | 3.5.6 |
| GhostBSD | devel/py-greenlet | 3.5.6 |
Install
Binary package:
pkgin install py311-greenlet
From pkgsrc:
cd /usr/pkgsrc/devel/py-greenlet && make install clean
Packages
The version each package repository carries. “-” means the repository builds no package of it, “n/a” that there is no such repository.
| Repository | Version |
|---|---|
| NetBSD 10.1 x86_64 | 3.5.5 |
| NetBSD 10.1 aarch64 | 3.5.1 |
| SmartOS / illumos x86_64 | 3.5.6 |
| macOS 15 arm64 | 3.5.6 |
Dependencies
Run dependencies 1
Configuration
No options to configure.
- Service scripts
- none
- Flavors
py312-greenlet-3.5.5,py313-greenlet-3.5.5,py314-greenlet-3.5.5