Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 11 additions & 20 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Run Tests
on: [push, pull_request]
env:
UV_PYTHON_DOWNLOADS: never
PYTEST_ADDOPTS: "--color=yes"
jobs:
tests:
Expand All @@ -12,7 +13,7 @@ jobs:
- os: ubuntu-latest
jack: jackd1
# x86_64:
- os: macos-13
- os: macos-15-intel
# arm64:
- os: macos-latest
- os: windows-latest
Expand Down Expand Up @@ -41,40 +42,30 @@ jobs:
shell: bash
run: |
jackd --no-realtime -d dummy &
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3"
- name: Double-check Python version
run: |
python --version
- uses: actions/checkout@v5
- name: Install uv
uses: astral-sh/setup-uv@v6
- name: Install Python package
run: |
python -m pip install .
- name: Install pytest
run: |
python -m pip install pytest
uv sync --locked
uv run jack_build.py
- name: Run tests
run: |
python -m pytest
uv run pytest

docs:
runs-on: ubuntu-latest
steps:
- name: Set up Python
uses: actions/setup-python@v6
- uses: actions/checkout@v5
with:
python-version: "3"
fetch-depth: 0
- name: Double-check Python version
run: |
python --version
- uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Install doc dependencies
run: |
python -m pip install -r doc/requirements.txt
python -m pip install --upgrade pip
python -m pip install --group doc
- name: Create HTML docs
run: |
python -m sphinx -W --keep-going --color -d _build/doctrees doc _build/html -b html
Expand Down
8 changes: 4 additions & 4 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
version: 2
build:
os: "ubuntu-22.04"
os: "ubuntu-24.04"
tools:
python: "3"
jobs:
post_checkout:
- git fetch --unshallow || true
install:
- pip install --upgrade pip
- pip install --group doc .
sphinx:
configuration: doc/conf.py
python:
install:
- requirements: doc/requirements.txt
13 changes: 7 additions & 6 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ newest development version from Github_::

git clone https://github.com/spatialaudio/jackclient-python.git
cd jackclient-python
python3 -m pip install -e .
python -m pip install -e .
python jack_build.py

... where ``-e`` stands for ``--editable``.
This way, your installation always stays up-to-date, even if you pull new
Expand All @@ -29,24 +30,24 @@ If you make changes to the documentation, you can locally re-create the HTML
pages using Sphinx_.
You can install it and a few other necessary packages with::

python3 -m pip install -r doc/requirements.txt
python -m pip install -r doc/requirements.txt

To create the HTML pages, use::

python3 setup.py build_sphinx
python -m sphinx doc _build

The generated files will be available in the directory ``build/sphinx/html/``.
The generated files will be available in the directory ``_build/``.

.. _Sphinx: https://www.sphinx-doc.org/

There are no proper tests (yet?), but the code examples from the README file
can be verified with pytest_.
If you haven't installed it already, you can install it with::

python3 -m pip install pytest
python -m pip install pytest

As soon as pytest_ is installed, you can run the (rudimentary) tests with::

python3 -m pytest
python -m pytest

.. _pytest: https://pytest.org/
6 changes: 0 additions & 6 deletions MANIFEST.in

This file was deleted.

10 changes: 5 additions & 5 deletions doc/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ Installation

You can use ``pip`` to install the ``jack`` module::

python3 -m pip install JACK-Client
python -m pip install JACK-Client

Depending on your Python installation (see `Requirements`_ below),
you may have to use ``python`` instead of ``python3``.
you may have to use ``python3`` instead of ``python``.
If you have installed the module already, you can use the ``--upgrade`` flag to
get the newest release.

To un-install, use::

python3 -m pip uninstall JACK-Client
python -m pip uninstall JACK-Client

Requirements
------------
Expand All @@ -38,7 +38,7 @@ pip/setuptools:
page.
If you happen to have ``pip`` but not ``setuptools``, use this command::

python3 -m pip install setuptools
python -m pip install setuptools

To upgrade to a newer version of an already installed package (including
``pip`` itself), use the ``--upgrade`` flag.
Expand Down Expand Up @@ -71,7 +71,7 @@ NumPy (optional):
You can also install NumPy with ``pip``, but depending on your platform, this
might require a compiler and several additional libraries::

python3 -m pip install NumPy
python -m pip install NumPy

.. _JACK: https://jackaudio.org/
.. _NumPy: https://numpy.org/
Expand Down
2 changes: 0 additions & 2 deletions doc/requirements.txt

This file was deleted.

2 changes: 1 addition & 1 deletion jack_build.py
Original file line number Diff line number Diff line change
Expand Up @@ -318,4 +318,4 @@
""", packed=True)

if __name__ == '__main__':
ffibuilder.compile(verbose=True)
ffibuilder.compile(tmpdir='src', verbose=True)
41 changes: 40 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,42 @@
[build-system]
requires = ["setuptools >= 61.0"]
requires = ["setuptools", "setuptools-scm", "cffi"]
build-backend = "setuptools.build_meta"

[project]
name = "JACK-Client"
license = "MIT"
dynamic = ["version"]
description = "JACK Audio Connection Kit (JACK) Client for Python"
readme = "README.rst"
keywords = ["JACK", "audio", "low-latency", "multi-channel"]
authors = [{ name = "Matthias Geier", email = "[email protected]" }]
classifiers = [
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Topic :: Multimedia :: Sound/Audio",
]
requires-python = ">=3.7"
dependencies = ["cffi"]

[project.urls]
Documentation = "http://jackclient-python.readthedocs.io/"
Repository = "https://github.com/spatialaudio/jackclient-python/"
Issues = "https://github.com/spatialaudio/jackclient-python/issues"

[dependency-groups]
dev = [{ include-group = "test" }, { include-group = "doc" }]
test = ["pytest"]
doc = [
"insipid-sphinx-theme",
"sphinx-last-updated-by-git",
]

[tool.setuptools]
py-modules = ["jack", "_jack"]

[tool.setuptools.packages.find]
where = ["src"]

[tool.setuptools.dynamic]
version = { attr = "jack.__version__" }
33 changes: 0 additions & 33 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,38 +1,5 @@
from setuptools import setup

__version__ = 'unknown'

# "import" __version__
for line in open('src/jack.py'):
if line.startswith('__version__'):
exec(line)
break

setup(
name='JACK-Client',
version=__version__,
package_dir={'': 'src'},
py_modules=['jack'],
setup_requires=['CFFI>=1.0'],
install_requires=['CFFI>=1.0'],
python_requires='>=3.7',
extras_require={'NumPy': ['NumPy']},
cffi_modules=['jack_build.py:ffibuilder'],
author='Matthias Geier',
author_email='[email protected]',
description='JACK Audio Connection Kit (JACK) Client for Python',
long_description=open('README.rst').read(),
license='MIT',
keywords='JACK audio low-latency multi-channel'.split(),
url='http://jackclient-python.readthedocs.io/',
platforms='any',
classifiers=[
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3 :: Only',
'Topic :: Multimedia :: Sound/Audio',
],
zip_safe=True,
)
Loading