Skip to main content

pysnippets

Python Snippets

Installation

pip install pysnippets

Usage

dict:

In [1]: from pysnippets import dictsnippets as dsn

In [2]: dsn.filter({'a': 1, 'b': 2, 'c': 3}, ['c', 'd:4'])
Out[2]: {'c': 3, 'd': 4}

In [3]: dsn.filter({'a': 1, 'b': 2, 'c': 3}, ['c', 'd:4'], exec_eval=False)
Out[3]: {'c': 3, 'd': '4'}

In [4]: dsn.gets({'a': 1, 'b': 2, 'c': 3}, ['c', 'd:4'])
Out[4]: [3, 4]

In [5]: dsn.gets({'a': 1, 'b': 2, 'c': 3}, ['c', 'd:4'], exec_eval=False)
Out[5]: [3, '4']

list:

In [1]: from pysnippets import listsnippets as lsn

In [2]: lsn.all([1, 2, 3], [1, 2])
Out[2]: True

In [3]: lsn.any([1, 2, 3], [1, 5])
Out[3]: True

str:

In [1]: from pysnippets import strsnippets as ssn

In [2]: ssn.strip(None)

In [3]: ssn.strip(' xyz ')
Out[3]: 'xyz'

Metadata

Release files for pysnippets 1.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pysnippets 1.1.4
File Size Uploaded Provenance Actions
pysnippets-1.1.4.tar.gz 3.3 kB Without provenance Details for pysnippets-1.1.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pysnippets 1.1.4
File Interpreter ABI Platform Actions
pysnippets-1.1.4-py2.py3-none-any.whl Python 3, Python 2 none any Details for pysnippets-1.1.4-py2.py3-none-any.whl

Total release size: 7.7 kB

Release files / pysnippets-1.1.4.tar.gz

Download URL pysnippets-1.1.4.tar.gz
Size 3.3 kB
Tags Source
SHA-256 checksum
How to use checksums
6feb51711388348e35500fcff87f44f2a542cb7196c3ff1f01627507d41bddb9
BLAKE2b-256 checksum
How to use checksums
9abe5fc85436e7a66563bdcb587e1c4852251629194b5f1ab30bededca305ff9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.2

Release files / pysnippets-1.1.4-py2.py3-none-any.whl

Download URL pysnippets-1.1.4-py2.py3-none-any.whl
Size 4.4 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
d3f0050d5f2b089de0259e2d618a35cc3443b841be8b2e42bae1a9692eb98088
BLAKE2b-256 checksum
How to use checksums
8f4c2feaa9820e333bc2d8df01548606ca6f2db6632e2ea38509dff1c0589c6d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.2

Security for pysnippets 1.1.4

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page