Unicecream
A simple formatter for removing icecream from your code after debugging.
Example
lyaguxa@thinkpad:$ cat somefile.py
from icecream import ic
def return_one() -> int:
return 1
ic(return_one())
lyaguxa@thinkpad:$ unicecream --check somefile.py
somefile.py:6:1: IC001 remove icecream call
somefile.py:1:1: IC003 remove icecream from-import
lyaguxa@thinkpad:$ unicecream somefile.py
fixed: somefile.py
lyaguxa@thinkpad:$ cat somefile.py
def return_one() -> int:
return 1
return_one()
Installation
pip install unicecream # for pyproject in python3.9 install unicecream[toml]
Usage
usage: unicecream [-h] [--check] [--select CODE] [--ignore CODE] [--version] path
Remove icecream debug calls from Python files
positional arguments:
path
optional arguments:
-h, --help show this help message and exit
--check
--select CODE Select rule code
--ignore CODE Ignore rule code
--version show program's version number and exit
Configuration
In pyproject:
[tool.unicecream]
# Rules to enable by default
select = ["IC001", "IC002", "IC003"]
# Rules to ignore
ignore = []
# Paths to skip
exclude = [
".venv",
"__pycache__",
"build",
"dist"
]
Pre-commit
repos:
- repo: https://github.com/lyaguxafrog/unicecream
rev: 0.2.1 # 0.2.1 is the minimum version that supports pre-commit.
hooks:
- id: unicecream
Metadata
Release files for unicecream 0.2.1
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 |
|---|---|---|---|---|
| unicecream-0.2.1.tar.gz | 4.5 kB | Without provenance | Details for unicecream-0.2.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| unicecream-0.2.1-py3-none-any.whl | Python 3 | none | any | Details for unicecream-0.2.1-py3-none-any.whl |
Total release size: 13.0 kB
Release files / unicecream-0.2.1.tar.gz
| Download URL | unicecream-0.2.1.tar.gz |
|---|---|
| Size | 4.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e5b2d49938aa069c24d31ab7a5be4ec5c0d9bad96f1d3d3551721ea1836c96bd
|
|
BLAKE2b-256 checksum How to use checksums |
5312f403a036f2b2a3e1afbd207fa39b69a0275019dbbcc01049524c3e355a80
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / unicecream-0.2.1-py3-none-any.whl
| Download URL | unicecream-0.2.1-py3-none-any.whl |
|---|---|
| Size | 8.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
17c69ae6818d926b5ea43e7f7cb4a688e34b4b503e48b059a54a0555ad787505
|
|
BLAKE2b-256 checksum How to use checksums |
afa2c940aaa222a697db3de8bc1a3f9cb56feac551b79e7e38d0a9f74f239cbe
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.10.6 {"installer":{"name":"uv","version":"0.10.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for unicecream 0.2.1
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.