Vanta
A lightweight Python toolkit for clean, structured CLI output.
- Colored messages
- Timestamps & log levels
- Input & confirmations
- Exception handling
- Terminal utilities
- Automatic color detection
- Interactive / non-interactive mode
- Simple terminal tables
Installation
pip install vanta
Quick Start
import vanta
console = vanta.Console()
console.info("Hello, World!")
table = vanta.Table("Name", "Age", "Status")
table.add_row("Alice", 17, "Online")
table.print()
Console
console = vanta.Console(
color=None, # Auto-detect colors
cls=False, # Don't clear the terminal on startup
*,
stdout=None, # Output stream for normal messages
stderr=None, # Output stream for warnings/errors
interactive=None, # Auto-detect interactive mode
level="info", # Minimum log level
)
Options
| Option | Description |
|---|---|
color |
Enable/disable colors |
cls |
Clear terminal on startup |
stdout |
Output stream for normal messages |
stderr |
Output stream for warnings/errors |
interactive |
Enable/disable input |
level |
Minimum log level |
Log Levels
Vanta provides 7 log levels:
| Level | Value | Stream | Purpose |
|---|---|---|---|
debug |
10 | stdout | Detailed debugging information |
info |
20 | stdout | General information |
notice |
25 | stdout | Important information worth noting |
success |
30 | stdout | Successful operation |
warning |
40 | stderr | Something may be wrong |
error |
50 | stderr | An operation failed |
critical |
60 | stderr | Serious/critical failure |
Lower levels are more verbose.
Console.debug()messages won't be shown iflevel="info"set!
Examples
Logging
console.debug("Debug")
console.info("Info")
console.notice("Notice")
console.success("Success")
console.warning("Warning")
console.error("Error")
console.critical("Critical")
Set a minimum log level:
console = vanta.Console(level="warning")
For example, level="warning" only emits warning, error, and critical messages.
Input
name = console.ask("Name:")
age = console.ask("Age:", int)
if console.confirm("Continue?"):
print("Continuing!")
ask() supports custom converters and retries.
Exceptions
try:
1 / 0
except Exception as exc:
console.exception(exc)
Use traceback=True for the full traceback.
Terminal
console.clear()
print(console.width)
Vanta works on Windows, Linux, and macOS.
Colors can also be controlled with NO_COLOR and FORCE_COLOR.
Methods
console.debug(...)
console.info(...)
console.notice(...)
console.success(...)
console.warning(...)
console.error(...)
console.critical(...)
console.raw(...)
console.ask(...)
console.confirm(...)
console.exception(...)
console.clear(...)
Tables
table = vanta.Table(
"Name", # Column 1
"Age", # Column 2
"Status", # Column 3
...,
align="left", # Align cell text to the left
border=True, # Show table and cell borders
header=True, # Include column headers
)
Options
| Option | Description |
|---|---|
align |
Align cell text |
border |
Show table and cell borders |
header |
Include column headers |
align can be left, center, or right.
Examples
table = vanta.Table("Name", "Age", "Status")
table.add_row("Alice", 17, "Online")
table.add_row("Bob", 21, "Offline")
table.print()
Output:
┌───────┬─────┬─────────┐
│ Name │ Age │ Status │
├───────┼─────┼─────────┤
│ Alice │ 17 │ Online │
│ Bob │ 21 │ Offline │
└───────┴─────┴─────────┘
Methods
table.add_row(...)
table.add_rows(...)
table.clear()
table.render() # Returns the table as a string
table.print() # Renders and prints the table
Version
0.3.0
Vanta is currently in early development and the API may change before 1.0.0.
License
See LICENSE.
Release files for vanta 0.3.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 | |
|---|---|---|---|
| vanta-0.3.0.tar.gz | 21.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| vanta-0.3.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 37.4 kB
Release files / vanta-0.3.0.tar.gz
| Download URL | vanta-0.3.0.tar.gz |
|---|---|
| Size | 21.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
04fd24a69b344bcbd5bfefae0dd8e6fb50758d7bd9ae84cc8be135c74cb9330e
|
|
BLAKE2b-256 checksum How to use checksums |
6fe0e3bf87d89f1cde7098f122db361ba55f9da40f2991309acc41fc78e224e7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 20, 2026.
Transparency logRelease files / vanta-0.3.0-py3-none-any.whl
| Download URL | vanta-0.3.0-py3-none-any.whl |
|---|---|
| Size | 15.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
86f0cf980620c2dd8d5ab513a5cb8d4305d9c645b45bbcfb92a5fe4beb8576ec
|
|
BLAKE2b-256 checksum How to use checksums |
8e7c43b7d5f63121c6d7f7ded1e00978229cfc6a1ef0be98925a51d366d4a174
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 20, 2026.
Transparency log