Skip to content

Fix the library and modernize the project - #13

Open
pganssle wants to merge 11 commits into
masterfrom
modernize
Open

pganssle wants to merge 11 commits into
masterfrom
modernize

Conversation

@pganssle

Copy link
Copy Markdown
Collaborator

Turns out this library has been broken all along, but this fixes it. I have been neglecting it so long that it was previously only set up to be tested in Python 3.6 and 3.7 using Travis and with all the build configuration in setup.py, so, I've also gone ahead and done some basic modernization.

Replacing #12 with this because apparently GHA won't trigger a new workflow when the PR is from a branch in a forked repo.

pganssle added 11 commits July 16, 2026 09:44
This seems to be doing some frame decoding now, but not like... well.
In order to fix this, we needed to preallocate the PCM array before
passing it to minimp3, match and initialize the existing C structures
and pass buffer.data.as_uchars directly instead of passing a
null-terminated string (buffer.data.as_uchars[:]).

Turns out I was also not comparing apples to apples with the mp3 and wav
comparsion, either.
The package metadata and test configuration still targeted Python 3.6 and 3.7. Update the supported-version classifiers, tox environments and development dependency minimums for Python 3.10+.
Run the test suite on Python 3.10, 3.14 and free-threaded 3.14 under Ubuntu and Windows. Add a separate job for the Black and isort checks.
The implementation is a Cython extension, so describe its Python-facing interface in a stub and mark the package as typed. Re-export that interface from pyminimp3 and check the source tree with pyrefly in tox and CI.
Keep setuptools as the build backend, but move the package metadata, package discovery, typed package data and Cython extension declaration into pyproject.toml. Update the build tox environment to build and check both distributions.

Make the source distribution manifest explicit so local virtual environments and scratch files are not swept up by the old recursive Python glob.
Upload coverage data from each test matrix job and combine it into a Markdown workflow summary, with an HTML artifact for more detail. This replaces the old Codecov tox environment without enforcing a minimum coverage percentage.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant