Python library to improve console printing by adding context to your prints. It makes your console much cleaner, and you won't have to worry about making your prints beautiful.
Warning: This library is not maintained anymore and its implementation uses questionable python tricks. It is advised for anyone interested in continuing it to figure out a better implementation and to start over with an entirely new project. A fork with more some additional features and more maintenance efforts is available at https://pypi.org/project/context-verbose/
Installation:
pip install secprint
Basic usage example:
from secprint import SectionPrinter as Spt
Spt.enter_section('Main section', color='blue')
Spt.print('Text in main section')
for i in range(3):
Spt.enter_section('Subsection {}'.format(i + 1))
Spt.print('Text in subsection')
Spt.print('Text in subsection')
Spt.exit_section()
Spt.exit_section()
The above example will print the following:
Advanced usage example, using contexts and automatic line skips when exiting sections:
from secprint import SectionPrinter as Spt
Spt.set_automatic_skip(True)
with Spt("Main section", color="blue"):
Spt.print('Text in main section')
for i in range(3):
with Spt(f"Subsection {i + 1}"):
Spt.print('Text in subsection')
Spt.print('Text in subsection')
The above example will print the following:
Metadata
Release files for secprint 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 |
|---|---|---|---|---|
| secprint-0.1.0.tar.gz | 7.5 kB | Without provenance | Details for secprint-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| secprint-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for secprint-0.1.0-py3-none-any.whl |
Total release size: 13.1 kB
Release files / secprint-0.1.0.tar.gz
| Download URL | secprint-0.1.0.tar.gz |
|---|---|
| Size | 7.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a0b555cf9d097ed65d2be935816d256d6188c976530b97f4c66416fd502ce9c5
|
|
BLAKE2b-256 checksum How to use checksums |
d1fea51f9b1df14710d8d05e59bf916ffce81ef37171d13067348e521843f959
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
pdm/2.10.0 CPython/3.10.10
|
Release files / secprint-0.1.0-py3-none-any.whl
| Download URL | secprint-0.1.0-py3-none-any.whl |
|---|---|
| Size | 5.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8afd59830f025f29f5a05f7c3e07ba0247e7b6d2dd3a521a0ebd6ed8bec74522
|
|
BLAKE2b-256 checksum How to use checksums |
881c53de9836f0420500a658a358d2d9da41dbcde182a56d2d2fbad2dab72f77
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
pdm/2.10.0 CPython/3.10.10
|
Security for secprint 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.