Skip to main content

Bootstrap your application and emit a Main event to ModuVent.

Project description

Ventrun

Bootstrap your application and emit a Main event to ModuVent.

Overview

Ventrun is a Python library and command-line tool that provides an event-driven framework for registering and executing main program entry points. Built on top of the moduvent event system, it automatically discovers and runs registered events from your project modules, making application initialization and execution more organized and maintainable.

Features

  • Automatic Module Discovery: Scans your project directory and automatically loads Python modules

  • Event-Driven Architecture: Register main entry points as events using a simple decorator

  • Dual Interface: Use as both a command-line tool and a Python library

  • Flexible Path Handling: Works with both absolute and relative paths, with current directory as default

  • Verbose Logging: Optional verbose output for debugging and monitoring

Installation

pip install ventrun

Quick Start

As a Command-Line Tool

# Scan current directory
ventrun

# Scan specific project directory
ventrun /path/to/your/project

# Enable verbose output
ventrun -v /path/to/your/project

As a Python Library

from moduvent import subscribe
from ventrun import Main


@subscribe(Main)
def main(e):
    print("Hello, world!")

For more information about moduvent, see the moduvent documentation.

License

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ventrun-1.3.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ventrun-1.3-py3-none-any.whl (3.8 kB view details)

Uploaded Python 3

File details

Details for the file ventrun-1.3.tar.gz.

File metadata

  • Download URL: ventrun-1.3.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.2

File hashes

Hashes for ventrun-1.3.tar.gz
Algorithm Hash digest
SHA256 d19b94290b9357874621254e4d8ad79d2f29a37c657d7d53302c898159afb5a0
MD5 49e27dfdcfa7fc9b64c4e44bccff2c5a
BLAKE2b-256 aa80c4781f73badc82ec4ec2d8187d32a6687b18f7609acf72058b9e85e5add8

See more details on using hashes here.

File details

Details for the file ventrun-1.3-py3-none-any.whl.

File metadata

  • Download URL: ventrun-1.3-py3-none-any.whl
  • Upload date:
  • Size: 3.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.2

File hashes

Hashes for ventrun-1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 2e5a38081bc5305c6ec6f69ce5db3c64e80edd71b3e247baa74cc299968aa6f1
MD5 ad5979dbe72232d85c926f0ea4ebdb28
BLAKE2b-256 39fe89fa969d60fa864fb671710b7454bdc4f23f8758983c725983ab65f1918c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page