Skip to main content

Elastic Framework Builder

Project description

SPOC

title-image

License: MIT Language GitHub PyPI Downloads

SPOC is a Python framework for building modular monolithic applications. Inspired by Django's app system, it provides automatic module discovery, dependency management, and lifecycle orchestration.

Features

  • App-based architecture - Organize code into self-contained, reusable modules
  • Automatic discovery - Apps and components are discovered and loaded at runtime
  • Dependency management - Define module dependencies with automatic load ordering
  • Component registry - Register and retrieve components using decorators
  • Lifecycle hooks - Startup and shutdown hooks for proper resource management
  • TOML configuration - Simple configuration with spoc.toml

Installation

Requires Python 3.13+

pip install spoc

Quick Start

from pathlib import Path
from spoc import Framework, Schema

# Define your application schema
schema = Schema(
    modules=["models", "views"],
    dependencies={"views": ["models"]},
)

# Create and run the framework
framework = Framework(
    base_dir=Path(__file__).parent,
    schema=schema,
)

# Access registered components
print(framework.components.models.values())

Documentation

For detailed documentation, tutorials, and examples:

Read the Docs

Links

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

spoc-0.3.1.tar.gz (3.4 MB view details)

Uploaded Source

Built Distribution

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

spoc-0.3.1-py3-none-any.whl (29.4 kB view details)

Uploaded Python 3

File details

Details for the file spoc-0.3.1.tar.gz.

File metadata

  • Download URL: spoc-0.3.1.tar.gz
  • Upload date:
  • Size: 3.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","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}

File hashes

Hashes for spoc-0.3.1.tar.gz
Algorithm Hash digest
SHA256 841705674c14d3811e7df4b7030fb2529368d1b8f8c569d969e32bc33fc7d1e6
MD5 38962d9d2860f0b9cc0553f4e97cda6f
BLAKE2b-256 6015a523b099e8c2deed7fc865b1a4a3add51ac690f1e475f9730a6d41f3ce1e

See more details on using hashes here.

File details

Details for the file spoc-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: spoc-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 29.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","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}

File hashes

Hashes for spoc-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 757843639e383b12dd6be6b191288bd0f801863d024299fb912132f77c7fd7a6
MD5 ba1cb8c769c3cfd84c6079de2813b7f1
BLAKE2b-256 f74d7b333f28e6ed1baba31c69fc41a13d39501400e53be27602a4824d534e19

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