semvec/pypi-packages huggingface dataset:
mini-apollo 0.1.2
A lightweight Python SDK for Apollo Config.
Requires Python: >=3.9

# Mini Apollo

A lightweight Python SDK for Apollo Config.

## Installation

```bash
pip install mini-apollo
```

## Quick Start

```python
from mini_apollo import ApolloClient, ApolloConfig

# Basic client setup
client = ApolloClient(
    server_url="http://your-apollo-server:8080",
    app_id="your-app-id",
    secret="your-secret"
)

# Fetch config once
config = client.fetch_config()
print(config.get("db.host"))

# Auto-refreshing config
config = ApolloConfig(
    client=client,
    auto_refresh=True,
    refresh_interval=30
)
print(config["http.timeout"])
```

## Async Support

```python
import asyncio
from mini_apollo import ApolloClient

async def main():
    client = ApolloClient(
        server_url="http://your-apollo-server:8080",
        app_id="your-app-id"
    )
    
    config = await client.async_fetch_config()
    print(config.get("db.host"))

asyncio.run(main())
```

## Configuration Options

```python
from mini_apollo import ApolloClient, ApolloConfig

client = ApolloClient(
    server_url="http://your-apollo-server:8080",
    app_id="your-app-id"
)

# Specify cluster and namespace
config = client.fetch_config(
    cluster="production",
    namespace="database"
)

# Background refresh
config = ApolloConfig(
    client=client,
    cluster="production",
    namespace="database",
    auto_refresh=True,
    refresh_interval=60
)
```

## Pydantic Integration

```python
from functools import cached_property

from pydantic import Field, computed_field
from pydantic_settings import BaseSettings, SettingsConfigDict

from mini_apollo import ApolloClient, ApolloConfig


class AppSettings(BaseSettings):
    apollo_server_url: str = Field(..., description="Apollo Server URL")
    apollo_app_id: str = Field(..., description="Apollo App ID")
    apollo_cluster: str = Field("default")
    apollo_namespace: str = Field("application")

    model_config = SettingsConfigDict(env_file=".env")

    @computed_field
    @cached_property
    def apollo_client(self) -> ApolloClient:
        return ApolloClient(
            server_url=self.apollo_server_url,
            app_id=self.apollo_app_id
        )

    @computed_field
    @cached_property
    def apollo_config(self) -> ApolloConfig:
        return ApolloConfig(
            client=self.apollo_client,
            cluster=self.apollo_cluster,
            namespace=self.apollo_namespace,
            auto_refresh=True,
            refresh_interval=30
        )

    @computed_field
    @property
    def db_host(self) -> str:
        return self.apollo_config["db.host"]


# Usage
settings = AppSettings()
print(f"Database host: {settings.db_host}")
```
milliedashmaker 0.1.1
This package allows users to create templates of dash projects
Requires Python: >=3.10

# MILLIEDASHMAKER



A brief description of what your project does.

## Table of Contents

- [Installation](#Installation)
- [Usage](#usage)
- [Contact Information](#contact-information)

## Installation

1. Ensure you have Python 3.6 or higher installed.
2. `pip install milliedashmaker`


## Usage

1. `dashed` prints out to the stdout the usage of the tool
2. `dashed new [PROJECT_NAME]` creates a new project in your folder `~/dash-projects/[PROJECT_NAME]`, and prints out the directory path
3. `dashed delete [PROJECT_NAME]` deletes projects that were created in the same `~/dash-projects/[PROJECT_NAME]`. Silently fails if project not found


## Contact Information

You can contact the creator at:
baodebug 0.1.0
An simple Python package for debug
Requires Python: >=3.8
Keywords: dumpvisz, logging

## Python usage

```
import baodebug

baodebug.debugutils.ConfigureRootLogger("info")  # config logger format
baodebug.debugutils.SetDebugPath("/root/visz/")  # create debug folder here and set to os.environ["DEBUG_PATH"]

import logging
logger = logging.getLogger(__name__)

logger.info("this will be printed in green")
```