Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

The Bazaar Compute Node Core

Declare contrib lifespans and services, then run them in a ContribHub.

import asyncio
from contextlib import asynccontextmanager

from bazaar_core import (
    Composition,
    Context,
    Contrib,
    ContribEntry,
    ContribHub,
    ServiceKey,
)

MESSAGES = ServiceKey[list[str]]("messages")


@asynccontextmanager
async def messages_lifespan(ctx: Context):
    ctx.offer(MESSAGES, [])
    yield


@asynccontextmanager
async def greeting_lifespan(ctx: Context):
    ctx.accept(MESSAGES).append("Hello")
    yield


messages = Contrib(offers=[MESSAGES], lifespan=messages_lifespan)
greeting = Contrib(accepts=[MESSAGES], lifespan=greeting_lifespan)


async def use_messages():
    async with (
        ContribHub() as hub,
        hub.enable(
            Composition(
                entries=[
                    ContribEntry(name="greeting", definition=greeting),
                    ContribEntry(name="messages", definition=messages),
                ]
            )
        ),
    ):
        for instance in hub.snapshots:
            print(instance.name, instance.state)


asyncio.run(use_messages())

Metadata

Release files for bazaar-core 0.3.0rc7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bazaar-core 0.3.0rc7
File Size Uploaded Provenance Actions
bazaar_core-0.3.0rc7.tar.gz 24.5 kB Without provenance Details for bazaar_core-0.3.0rc7.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for bazaar-core 0.3.0rc7
File Interpreter ABI Platform Actions
bazaar_core-0.3.0rc7-py3-none-any.whl Python 3 none any Details for bazaar_core-0.3.0rc7-py3-none-any.whl

Total release size: 53.1 kB

Release files / bazaar_core-0.3.0rc7.tar.gz

Download URL bazaar_core-0.3.0rc7.tar.gz
Size 24.5 kB
Tags Source
SHA-256 checksum
How to use checksums
2dfbdf7e9ef4d4d8e22fc9155a21c0940a9ea4dc35b2bbc5f6e18e49e2f99626
BLAKE2b-256 checksum
How to use checksums
3923f4749cb73037892cce84b5664f2dcddc9ccac0a98d5b275e635667a97913
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.0 {"installer":{"name":"uv","version":"0.13.0","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 / bazaar_core-0.3.0rc7-py3-none-any.whl

Download URL bazaar_core-0.3.0rc7-py3-none-any.whl
Size 28.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b74bf1cdafc556f917da5ea510a4e4c2b1dabbd2021c6ac05e20e11653f66d16
BLAKE2b-256 checksum
How to use checksums
8ad0c091153cd481af9be11c45c793ff01f84117c7829cbf9d74eac9d2cf2fce
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.0 {"installer":{"name":"uv","version":"0.13.0","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 bazaar-core 0.3.0rc7

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.

Release history Release notifications | RSS feed

This release
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page