Skip to main content

A modular Python application framework with manifest-driven module loading, lifecycle management, and contrib modules.

Project description

bedrock

bedrock is the runtime core of the Bedrock modular framework.

It provides manifest-driven module loading, lifecycle management, and first-party contrib modules for common capabilities.

Status

The core runtime is fully implemented and functional.

This package contains production-ready subsystems:

  • Module registry with dependency resolution and lifecycle hooks
  • Dependency injection container with singleton/transient/scoped lifetimes
  • Hook system for structured call/response extension points (sync, async, robust)
  • SQLAlchemy 2.0 database layer with Alembic migrations
  • Cache system with memory and Redis backends
  • Signal/event system (blinker-derived)
  • Typer-based CLI for module and database management
  • Comprehensive utility library (lazy loading, introspection, string helpers)

Installation

# With uv (recommended)
uv add bedrock-core

# With poetry
poetry add bedrock-core

# With pip
pip install bedrock-core

Quick Start

import bedrock

# Initialize the runtime (discovers and loads modules)
bedrock.setup()

# Access key singletons
from bedrock.module import apps          # ModuleRegistry
from bedrock.database import db          # DatabaseManager
from bedrock.contrib.cache import cache  # CacheService

Key Singletons

Singleton Class Import
apps ModuleRegistry from bedrock.module import apps
container Container from bedrock.di import container
hooks HookRegistry from bedrock.hooks import hooks
db DatabaseManager from bedrock.database import db
cache CacheService from bedrock.contrib.cache import cache

Module Structure

my_app/
├── __init__.py
├── manifest.yaml    # Module identity and dependencies
├── models.py        # SQLAlchemy models (optional)
├── entities.py      # Pydantic models for validation
├── service.py       # Business logic
├── exc.py           # Module exceptions
└── bootstrap.py     # Lifecycle hooks

Architecture

Bedrock is framework-agnostic by design. The core runtime has no HTTP dependencies and is usable in:

  • API servers (FastAPI, Flask, etc.)
  • Background workers (Celery, etc.)
  • CLI tools
  • Scripts and automation

For more details, see the documentation.

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

bedrock_core-0.1.2.tar.gz (73.3 kB view details)

Uploaded Source

Built Distribution

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

bedrock_core-0.1.2-py3-none-any.whl (103.2 kB view details)

Uploaded Python 3

File details

Details for the file bedrock_core-0.1.2.tar.gz.

File metadata

  • Download URL: bedrock_core-0.1.2.tar.gz
  • Upload date:
  • Size: 73.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for bedrock_core-0.1.2.tar.gz
Algorithm Hash digest
SHA256 0094d1d25e727d7ca1c8e57ec519b630e1ee5a85ed1c6cccb677fa3034a84636
MD5 cd2328f00e7d31a35b2fb1f35561a774
BLAKE2b-256 d443b3550345bd8fabba6bca74bfd65b5cb66a93efc20374b6fd86e5d6c69953

See more details on using hashes here.

Provenance

The following attestation bundles were made for bedrock_core-0.1.2.tar.gz:

Publisher: release.yml on maacck/bedrock-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file bedrock_core-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: bedrock_core-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 103.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for bedrock_core-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 7ba383553527a14a47b0a39f0d749a82b9adc8f315e55d4fdbc42ee3c0a51171
MD5 ae2ffa559dba071afbb982e5bb2e18f7
BLAKE2b-256 ee40077e9d30ffe64ac4b849dcaeaf9228aca13bf2f42a8a5b457f65f69a23f4

See more details on using hashes here.

Provenance

The following attestation bundles were made for bedrock_core-0.1.2-py3-none-any.whl:

Publisher: release.yml on maacck/bedrock-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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