semvec/pypi-packages huggingface dataset:
stevepromlpredictor 0.1.0
A simple machine learning package using scikit-learn
License: MIT
Requires Python: >=3.6

Building Python Packages
11-Nov-2024

https://medium.com/@ebimsv/building-python-packages-07fbfbb959a9

GitHub
https://github.com/Ebimsv/mlpredictor?source=post_page-----07fbfbb959a9--------------------------------


PyCharm
source .venv/bin/activate

pip install .
pip install --upgrade pip

NOTE:
had to manually install pytest
pytest


Publish
pip install twine build

python -m build
Successfully built mlpredictor-0.1.0.tar.gz and mlpredictor-0.1.0-py3-none-any.whl

dist folder w/ following files
.tar.gz
.whl


Upload
twine upload dist/*

COULD NOT get this working!

Follow instructions here
https://pypi.org/manage/account/token

Create API token
touch ~/.pypirc
gedit ~/.pypirc


https://stackoverflow.com/questions/57457879/why-cant-i-upload-my-own-package-to-pypi-when-my-credential-are-working
sglang-rust-test 0.1.12
A Python wrapper around Rust HelloWorld
License: MIT
Requires Python: >=3.8

# Building Rust with Python Bindings

## Prerequisites
- Rust and Cargo installed
- Python with pip installed

## Build Process

### 1. Build Rust Project
```bash
cargo build
```

### 2. Build Python Binding

#### Option A: Build and Install Wheel
1. Build the wheel package:
```bash
pip install setuptools-rust wheel build
python -m build
```

2. Install the generated wheel:
```bash
pip install <path-to-wheel>
```

#### Option B: Development Mode
For development purposes, you can install the package in editable mode:
```bash
pip install -e .
```

**Note:** When modifying Rust code, you must rebuild the wheel for changes to take effect.

## CI/CD Setup

The continuous integration pipeline consists of three main steps:

### 1. Build Wheels
- Uses `cibuildwheel` to create manylinux x86_64 packages
- Compatible with major Linux distributions (Ubuntu, CentOS, etc.)
- Additional configurations can be added to support other OS/architectures
- Reference: [cibuildwheel documentation](https://cibuildwheel.pypa.io/en/stable/)

### 2. Build Source Distribution
- Creates a source distribution containing the raw, unbuilt code
- Enables `pip` to build the package from source when prebuilt wheels are unavailable

### 3. Publish to PyPI
- Uploads both wheels and source distribution to PyPI

The CI configuration is based on the [tiktoken workflow](https://github.com/openai/tiktoken/blob/63527649963def8c759b0f91f2eb69a40934e468/.github/workflows/build_wheels.yml#L1).