cronipy
cronipy turns Python functions into cron jobs. You decorate a function with a schedule, run one command, and cronipy writes the crontab entries for you. The package is in early development, and the interface can change.
Installation
pip install cronipy
Usage
Define your jobs in a module of your package, e.g. mypackage.tasks:
from cronipy import Cron
cron = Cron()
@cron.task("*/5 * * * *")
def do_something_every_five_minutes():
...
Then install the jobs into your crontab:
cron.install()
or from a shell, install jobs from all Cron objects in the specified module:
$ cronipy install mypackage.tasks
cronipy adds one line per decorated function into the current user's crontab. Function output is logged in logs/<function name>.log.
Options
You can pass these arguments to Cron:
dry_run: when true, a job prints its name and does nothing.env: a dictionary of environment variables added to every crontab line.log_dir: where the log files go,./logsby default.work_dir: the directory each job runs in,./by default.python: the interpreter the jobs use, the one that runs cronipy by default.
Development
This repository uses uv. Set up a development environment with uv sync, and run the checks with uv run pytest.
Roadmap
- Enable autodiscovery of modules containing Cron objects.
- Enable compatibility with single-file modules.
License
Metadata
Release files for cronipy 0.1.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 |
|---|---|---|---|---|
| cronipy-0.1.1.tar.gz | 3.2 kB | Without provenance | Details for cronipy-0.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| cronipy-0.1.1-py3-none-any.whl | Python 3 | none | any | Details for cronipy-0.1.1-py3-none-any.whl |
Total release size: 7.1 kB
Release files / cronipy-0.1.1.tar.gz
| Download URL | cronipy-0.1.1.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
df7587c70f87350330ff21595081847aa5f88f5803943f2cf09ef4008b1a7d1b
|
|
BLAKE2b-256 checksum How to use checksums |
2611d55ca77274d2addef81eaa29e526d56119ef76cddb675e456ead4dd08eb2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.13.4 {"installer":{"name":"uv","version":"0.13.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Manjaro Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / cronipy-0.1.1-py3-none-any.whl
| Download URL | cronipy-0.1.1-py3-none-any.whl |
|---|---|
| Size | 3.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f44c2d44446139d855e31545700fe90e737c628f6657c03aa880144a4dab62fa
|
|
BLAKE2b-256 checksum How to use checksums |
8c27beb82c0d0b3191a56c4b9fb80d326fe8056bd77ca7e0484c57b6f4413eff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.13.4 {"installer":{"name":"uv","version":"0.13.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Manjaro Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for cronipy 0.1.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.