semvec/pypi-packages huggingface dataset:
community-solar-programs 0.1.0
Community solar regulation as code. A static library of functions that calculate compensation for various community solar programs.
Requires Python: >=3.11,<4.0

# Community Solar Programs

Community Solar Programs represented as code.

Understanding potential earnings from community solar programs is difficult. This library attempts to make it easy by encoding program compensation structures (defined in regulatory, policy, and other legislative documents) as runnable code.

# Developing 

```bash
poetry shell
poetry install
```

# Publishing

Refresh poetry lock file as per https://python-poetry.org/docs/basic-usage/#as-a-library-developer
```bash
poetry update
```

Run tests

```bash
poetry build
```
pyhatchbabyrest-hass 2.3.0
Python library to control Hatch Baby Rest devices
Requires Python: >=3.5

# Hatch Baby Rest Python Bindings
This library will allow you to control a [Hatch Baby Rest device](https://www.hatchbaby.com/rest) (note, /not/ the Hatch Baby Rest+, which is Wi-Fi enabled) over [BLE](https://en.wikipedia.org/wiki/Bluetooth_Low_Energy).

## Requirements
The pygatt backend was tested on a Raspberry Pi 3 Model B Rev 1.2, but should work on any Unix system that is compatible with the `GATTToolBackend` of [pygatt](https://github.com/peplin/pygatt).

The bleak (async) backend was tested on a 2019 MacBook Pro, but should work on any system that [bleak](https://github.com/hbldh/bleak) is compatible with.

## Installation
`pip install pyhatchbabyrest`

## Examples
### pygatt backend (synchronous)
```python3
In [1]: from pyhatchbabyrest import PyHatchBabyRest

In [2]: rest = PyHatchBabyRest()

In [3]: rest.power
Out[3]: False

In [4]: rest.power_on()

In [5]: rest.volume
Out[5]: 30

In [6]: rest.set_volume(10)

In [7]: rest.volume
Out[7]: 10

In [8]: rest.set_color(255, 0, 0)

In [9]: rest.color
Out[9]: (255, 0, 0)

In [10]: rest.set_brightness(100)

In [11]: rest.set_sound(PyHatchBabyRestSound.stream)

In [12]: rest.sound
Out[12]: <PyHatchBabyRestSound.stream: 2>

In [13]: rest.set_color(*PyHatchBabyRest.COLOR_GRADIENT)
    
In [14]: rest.connected
Out[14]: True

In [15]: rest.disconnect()

In [16]: rest.connected
Out[16]: False
```

### bleak backend (async and a little more portable)
```python3
In [1]: from pyhatchbabyrest import PyHatchBabyRestAsync

In [2]: rest = PyHatchBabyRestAsync()

In [3]: import asyncio

In [4]: loop = asyncio.get_event_loop()

In [5]: r = loop.run_until_complete

In [6]: r(rest.power_on())

In [7]: r(rest.set_volume(100))

In [8]: r(rest.set_volume(10))

In [9]: r(rest.power_off())

In [10]: rest.sound
Out[10]: <PyHatchBabyRestSound.noise: 3>
```

#### NOTE: Using PyHatchBabyRestAsync from async code
The constructor, by default, executes directly against the event loop. This doesn't work if it is executed within an already running coroutine. To construct the client, all async calls must be done outside of the constructor.

This has been all wrapped up in a function for ease of use.

```python3
import asyncio

from pyhatchbabyrest import connect_async


async def main():
    rest = await connect_async()
    await rest.power_on()


rest = asyncio.run(main())
```

## Credits
Huge thanks to @Marcus-L for their repo at [GitHub - Marcus-L/m4rcus.HatchBaby.Rest: Control Hatch Baby Rest devices using Bluetooth LE](https://github.com/Marcus-L/m4rcus.HatchBaby.Rest) which did all the hard work of finding the right characteristics, commands, etc.
jasmin-mongo-logger 0.2.0
Log Jasmin SMS Gateway MT/MO to MongoDB Cluster.
Requires Python: >=3.11

# Jasmin Mongo Logger

Log [Jasmin SMS Gateway](https://github.com/jookies/jasmin)'s MT/MO to MongoDB Cluster (can be a one-node cluster).

## Table of Contents

1. **[Installation Instructions](#installation-instructions)**
    + **[PYPI](#pypi)**
    + **[From Source](#from-source)**
2. **[Setup MongoDB CLuster](#setup-mongodb-cluster)**
3. **[Usage Instructions](#usage-instructions)**
    + **[Data Structure](#data-structure)**
    + **[Start the Service](#start-the-service)**

## Installation Instructions

### PYPI

```bash
pip3 install -U jasmin-mongo-logger
```

### From Source

```bash
git clone https://github.com/BlackOrder/jasmin_mongo_logger.git
cd jasmin_mongo_logger
pip3 install .
```

### Docker

```bash
docker compose -f ./docker/docker-compose.yml up -d
```

Be sure to change the `AMQP_BROKER_HOST` and `MONGO_CONNECTION_STRING` in the `docker-compose.yml` file to your desired values. and also finish the [setup of the MongoDB cluster](#setup-mongodb-cluster) before running the docker-compose file.

## Setup MongoDB CLuster

To setup a MongoDB cluster with Docker, You can use this open source [Docker Custom MongoDB Image](https://github.com/BlackOrder/mongo-cluster)

## Usage Instructions

`Jasmin Mongo Logger` Logs all MT/MO from `jasmin` to MongoDB Cluster. All settings are read from OS ENV when run from console. if you want to import it in you code, you can supply the settings on initialization.

### Data Structure

You have to supply a database and a collection name. The package will dump all data into the collection.

### Start the service

There is multiple ways to setup the package from CLI.

1. By exporting ENV variables
    you can export the fallowing variables before execution

    ```env
    AMQP_BROKER_HOST                    =              127.0.0.1
    AMQP_BROKER_PORT                    =                5672
    MONGO_CONNECTION_STRING             =       **REQUIRED:NoDefault**
    MONGO_LOGGER_DATABASE               =       **REQUIRED:NoDefault**
    MONGO_LOGGER_COLLECTION             =       **REQUIRED:NoDefault**
    JASMIN_MONGO_LOGGER_LOG_PATH        =          /var/log/jasmin/
    JASMIN_MONGO_LOGGER_LOG_LEVEL       =               INFO
    ```

    Then execute:

    ```bash
    jasminmongologd
    ```

2. You can pass arguments to the package on execution. execute ` jasminmongologd -h ` to see all possible arguments. Then execute:

    ```bash
    jasminmongologd --connection-string $MONGO_CONNECTION_STRING --database $MONGO_LOGGER_DATABASE --collection $MONGO_LOGGER_COLLECTION
    ```

3. Mix the previous two methods. you can set the ENV variables and pass some arguments. for example:

    ```bash
    AMQP_BROKER_HOST=127.0.0.1 jasminmongologd --connection-string $MONGO_CONNECTION_STRING --database $MONGO_LOGGER_DATABASE --collection $MONGO_LOGGER_COLLECTION
    ```
rpip 1.1
Utility to recursively install requirements using pip
Requires Python: >=3.6

# rpip - Recursively install python requirements from multiple directories using pip

Install via pip (`pip install rpip`).

Usage:
```
usage: rpip [-h] [-i [INCLUDE_DIRS [INCLUDE_DIRS ...]]] [-x [EXCLUDE_DIRS [EXCLUDE_DIRS ...]]] [--ignore-versions] [-v]
               [-o OUTPUT_FILE] [--dry-run] [-f [FILENAME [FILENAME ...]]] [--pip-path PIP_PATH]
               [root_path]

Recursive pip install of requirements files.

positional arguments:
  root_path             Root path to start searching for requirements files.

optional arguments:
  -h, --help            show this help message and exit
  -i [INCLUDE_DIRS [INCLUDE_DIRS ...]], --include-dirs [INCLUDE_DIRS [INCLUDE_DIRS ...]]
                        Pattern for directories to include.
  -x [EXCLUDE_DIRS [EXCLUDE_DIRS ...]], --exclude-dirs [EXCLUDE_DIRS [EXCLUDE_DIRS ...]]
                        Pattern for directories to exclude.
  --ignore-versions     Ignore version specification in requirements files.
  -v, --verbose         Print status messages.
  -o OUTPUT_FILE, --output-file OUTPUT_FILE
                        If specified, write the list of packages to this file instead of installing.
  --dry-run             Print what would be installed, but don't install anything.
  -f [FILENAME [FILENAME ...]], --filename [FILENAME [FILENAME ...]]
                        Pattern to match for requirements files. Defaults to "requirements.txt".
  --pip-path PIP_PATH   Specify the path to the pip executable.
```