Description
wirerope ======== .. image:: https://github.com/youknowone/wirerope/actions/workflows/python-package.yml/badge.svg .. image:: https://codecov.io/gh/youknowone/wirerope/graph/badge.svg :target: https://codecov.io/gh/youknowone/wirerope The concepts: - `wirerope.rope.WireRope` is a wrapper interface for python callable. - Custom `wirerope.wire.Wire` class provides user-defined behavior. A subclass of this class is working similar to a *decorator function* body. - A wire object is associated with a bound method. - Rope is dispatching types. `wirerope.rope.WireRope` is the wrapper for callables. By wrapping a function with `WireRope` with a custom subclass of the `wirerope.wire.Wire` class, the wire object will be created by each function or bound method. `Wire` is the most important part. The given class will be instantiated and bound to each function or bound method - which fits the concept of *instance cmethod* of human. For example, when `f` is a free function or staticmethod, the wire also will be a single object. When `f` is a method or property, wires will be created for each method owner object `self`. When `f` is a classmethod, wires will be created for each method owner class `cls`. Yes, it will detect the owner and bound to it regardless of the calling type. `Rope` is internal dispatcher. It will be helpful when creating a complex object for decorated callable instead of simple callable feature. See also -------- - See [documentation](https://wirerope.readthedocs.io/en/latest/) - though it is not yet written very well. - See `tests/test_wire.py` for simple example. - See [methodtools](https://github.com/youknowone/methodtools) for practical example. Python2 support --------------- wirerope 1.0 stops to support Python 2. If you need Python 2 support, use 0.4.7 the latest version for Python 2.
Release History
| Version | Changes | Urgency | Date |
|---|---|---|---|
| 1.0.0 | Imported from PyPI (1.0.0) | Low | 4/21/2026 |
| 0.4.8 | Tag 0.4.8 | Low | 11/9/2024 |
| 0.4.7 | Tag 0.4.7 | Low | 2/5/2023 |
| 0.4.6 | Tag 0.4.6 | Low | 2/17/2022 |
| 0.4.5 | Tag 0.4.5 | Low | 7/31/2021 |
| 0.4.4 | Tag 0.4.4 | Low | 7/31/2021 |
| 0.4.3 | Tag 0.4.3 | Low | 5/26/2021 |
| 0.4.2 | Tag 0.4.2 | Low | 7/6/2020 |
| 0.4.1 | Tag 0.4.1 | Low | 7/5/2020 |
| 0.4.0 | Tag 0.4.0 | Low | 7/3/2020 |
| 0.3.1 | Tag 0.3.1 | Low | 10/26/2019 |
| 0.3.0 | Tag 0.3.0 | Low | 10/24/2019 |
| 0.2.1 | Tag 0.2.1 | Low | 5/5/2019 |
| 0.1.1 | Tag 0.1.1 | Low | 6/24/2018 |
| 0.1.0 | Tag 0.1.0 | Low | 6/14/2018 |
