proxy_tools
I’m just a proxy
Loveingly extracted from werkzeug. A very useful proxy implementation, that I found to be useful outside the web context – hence the extraction.
Install
pip install proxy
Basic Usage
from proxy_tools import Proxy
p = Proxy()
def get_current_user():
return User.find_by_id(request['user_id'])
current_user = p(get_current_user)
# Or alternatively
from proxy_tools import module_property
@module_property
def current_user():
return User.find_by_id(request['user_id'])
# Then
print(current_user.name)
Questions / Issues
Feel free to ping me on twitter: @tushman or add issues or PRs at https://github.com/jtushman/proxy_tools
Thank you
To Armin Ronacher and the werkzeug team for their thought leadership and excellent work
Metadata
Release files for proxy_tools 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| proxy_tools-0.1.0.tar.gz | 3.0 kB | Without provenance | Details for proxy_tools-0.1.0.tar.gz |
Release files / proxy_tools-0.1.0.tar.gz
| Download URL | proxy_tools-0.1.0.tar.gz |
|---|---|
| Size | 3.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ccb3751f529c047e2d8a58440d86b205303cf0fe8146f784d1cbcd94f0a28010
|
|
BLAKE2b-256 checksum How to use checksums |
f2cf77d3e19b7fabd03895caca7857ef51e4c409e0ca6b37ee6e9f7daa50b642
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for proxy_tools 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.