Useful Python Tidbits
Project description
Ever find yourself copying and pasting small chunks of Python code between a bunch of your projects? The goal of this library is to reduce or eliminate that problem.
Yes, I realize that’s never going to happen. Contributions are very appreciated though, let’s see how close we can get.
Installation
$ pip install --upgrade tidbits
Note that in an effort to keep this library generalized, optional dependencies are not included, ie. for the Sentry integration you will still need to
$ pip install raven
Usage
Integrations
Do you use Sentry? I do. And every single project I use it in contains the same block for configuring it from the SENTRY_DSN environment variable.
from tidbits.integrations.sentry import SENTRY
try:
{}['missing_key']
except Exception:
# damn, I totally didn't expect an error here, better send it to Sentry
SENTRY.captureException()
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
tidbits-0.1.0.tar.gz
(2.6 kB
view hashes)
Built Distribution
Close
Hashes for tidbits-0.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3f137faa512271aea9daa4ebd7293c7f5bb76d02c6970ef21fe85846c8ea4fa0 |
|
MD5 | 13d8f91e8f8bece715b4818d48528a49 |
|
BLAKE2b-256 | d22c1bf14a1888d7866765533776efc8a600f2e8beb9410e2fa0f609b29b5469 |