Audacity .aup3 parser with Rust core and Python interface
Project description
aup-parser
aup-parser is an Audacity .aup3 parser package with a Rust core and typed Python interface.
Highlights
- Rust core for binary XML and sampleblocks analysis
- Class-based Python API (
AUPParser) withTypedDictreturn types - Optional audio export helper
- CLI entrypoint:
aup-parser
Package Layout
src/: Rust core (PyO3extension)python/aup_parser/: Python API, types, exports, and CLItests/: API/CLI/parity tests and golden fixtures
Build (local dev)
cd /Users/joonholee/deeply/aup3-parser
python3 -m pip install --user --break-system-packages maturin
python3 -m maturin build --release -i python3
python3 -m pip install --user --break-system-packages --force-reinstall target/wheels/aup_parser-*.whl
Python API (Class-only)
from aup_parser import AUPParser
parser = AUPParser("tests/test.aup3")
essential = parser.parse(profile="essential")
full = parser.parse(profile="full")
AUPParser.parse() signature:
def parse(
self,
*,
profile: Literal["essential", "full"] = "essential",
audio_output_path: str | pathlib.Path | None = None,
sample_rate: int = 48000,
) -> ParseResultTD: ...
audio_output_path:None이 아니면 WAV를 export- 싱글 채널 프로젝트: 단일 WAV 파일 출력
- 멀티 채널 프로젝트:
audio_output_path를 폴더로 사용하여 채널별 WAV 파일 생성 - 멀티 채널 + 파일처럼 보이는 경로(
out.wav) 입력 시: 자동으로out_channels/폴더로 정규화 - 타임라인 복원: clip metadata(
offset,trimLeft,trimRight)를 우선 적용하고, 불가능한 경우waveblock.start기준으로 배치 - gap 구간은 zero-fill, 겹침 구간은 later block overwrite 규칙 사용
sample_rate:audio_output_pathexport 시 사용할 샘플레이트
CLI
aup-parser tests/test.aup3 --json
aup-parser tests/test.aup3 --full-json --json
aup-parser tests/test.aup3 --json --audio-output-path /tmp/output --sample-rate 48000
Compatibility Notes
- Python 3.11+
abi3-py311build strategy- CI validates install + runtime parse on:
- Linux (
ubuntu-latest) - macOS (
macos-latest) - Windows (
windows-latest)
- Linux (
- Release wheels are built for:
- Linux (
ubuntu-latest) - Windows (
windows-latest) - macOS Intel (
macos-13) - macOS Apple Silicon (
macos-14)
- Linux (
- If a wheel is unavailable for your environment,
pipfalls back to sdist build and requires a Rust toolchain.
Release
GitHub Actions workflow (.github/workflows/release.yml) runs:
- Matrix tests on PRs
- Wheel/sdist build on version tags (
v*) - PyPI publish via trusted publishing
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
aup_parser-0.1.0.tar.gz
(24.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file aup_parser-0.1.0.tar.gz.
File metadata
- Download URL: aup_parser-0.1.0.tar.gz
- Upload date:
- Size: 24.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6d58b7d6f0dca2d9c2d0e35d336edaad537c7da562624be79932678460f97a98
|
|
| MD5 |
aa0d22b419081c006ea72e154c2f6445
|
|
| BLAKE2b-256 |
363c98b06852737ac656644b70d59b92badf027effd57bb836a06d8dc3f594eb
|
File details
Details for the file aup_parser-0.1.0-cp311-abi3-macosx_11_0_arm64.whl.
File metadata
- Download URL: aup_parser-0.1.0-cp311-abi3-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.2 MB
- Tags: CPython 3.11+, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3bebc6243424794a1244bb0e9b8d5e719cc703cceb46926e94c4dc2453eb8a90
|
|
| MD5 |
618d1c454471b8758aa0a6f14616331d
|
|
| BLAKE2b-256 |
948e370fbb030a5492aee831922be1c1bdb4056d430d80088a35f771ec90b653
|