Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to pyproject.toml instead of setup.py #183

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
10 changes: 5 additions & 5 deletions .github/workflows/publish-to-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ jobs:
publish-pypi:
runs-on: ubuntu-latest
steps:
- name: Set up Python 3.9
uses: actions/setup-python@v2
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: 3.9
python-version: 3.11

- name: Install tools
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
pip install setuptools wheel twine build

- name: Checkout tag ${{ github.event.inputs.tag }}
uses: actions/checkout@v2
Expand All @@ -31,7 +31,7 @@ jobs:

- name: Build source distribution and wheel
run: |
python setup.py sdist bdist_wheel
python -m build --sdist --wheel

- name: List distribution artifacts
run: |
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/publish-to-test-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ jobs:
publish-test-pypi:
runs-on: ubuntu-latest
steps:
- name: Set up Python 3.9
uses: actions/setup-python@v2
- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: 3.9
python-version: 3.11

- name: Install tools
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
pip install setuptools wheel twine build

- name: Checkout tag ${{ github.event.inputs.tag }}
uses: actions/checkout@v2
Expand All @@ -31,7 +31,7 @@ jobs:

- name: Build source distribution and wheel
run: |
python setup.py sdist bdist_wheel
python -m build --sdist --wheel

- name: List distribution artifacts
run: |
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ jobs:
test-docs:
runs-on: ubuntu-latest
steps:
- name: Set up Python 3.8
- name: Set up Python 3.11
uses: actions/setup-python@v2
with:
python-version: 3.8
python-version: 3.11

- name: Checkout repository
uses: actions/checkout@v2
Expand All @@ -33,7 +33,7 @@ jobs:
runs-on: ubuntu-20.04 # because Qt 6 requires glibc >= 2.28, which ubuntu-latest does not have
strategy:
matrix:
python-version: ['3.7', '3.8', '3.9']
python-version: ['3.9', '3.11']
qt-version: [PyQt5, PySide2, PySide6]
# exclude:
# - qt-version: PySide2
Expand Down
1 change: 0 additions & 1 deletion ephyviewer/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
from .version import version as __version__

#common tools
Expand Down
4 changes: 3 additions & 1 deletion ephyviewer/version.py
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
version = '1.7.1.dev0'
import importlib.metadata

version = importlib.metadata.version("ephyviewer")
64 changes: 64 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
[project]
name = "ephyviewer"
version = "1.7.1.dev0"
authors = [
{ name="Samuel Garcia", email="[email protected]" },
{ name="Jeffrey Gill"},
]

description = "Simple viewers for ephys signals, events, video and more"
readme = "README.rst"
requires-python = ">=3.8"
classifiers = [
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Intended Audience :: Science/Research",
"Natural Language :: English",
]

dependencies = [
"numpy",
"matplotlib>=2.0",
"pyqtgraph>=0.10.0",
"scipy",
]

[project.urls]
homepage = "https://github.com/NeuralEnsemble/ephyviewer/"
repository = "https://github.com/NeuralEnsemble/ephyviewer/"
documentation = "https://ephyviewer.readthedocs.io/en/latest/"
changelog = "https://ephyviewer.readthedocs.io/en/latest/releasenotes.html"


[build-system]
requires = ["setuptools>=62.0"]
build-backend = "setuptools.build_meta"


[tool.setuptools]
packages = ["ephyviewer"]
package-dir = {"ephyviewer" = "ephyviewer"}

[project.scripts]
ephyviewer = "ephyviewer.scripts:launch_standalone_ephyviewer"

[project.optional-dependencies]

tests = [
"av",
"coveralls",
"neo>=0.10.0",
"spikeinterface>=0.90.1",
"pandas",
"pytest",
"pytest-cov",
]

docs = [
# these restricted versions are defaults on ReadTheDocs, so use the same in
# local builds and in tests
"sphinx<2",
# see this https://github.com/readthedocs/readthedocs.org/issues/9037
"jinja2<3.1.0",
]
5 changes: 0 additions & 5 deletions requirements-docs.txt

This file was deleted.

7 changes: 0 additions & 7 deletions requirements-tests.txt

This file was deleted.

4 changes: 0 additions & 4 deletions requirements.txt

This file was deleted.

52 changes: 0 additions & 52 deletions setup.py

This file was deleted.

Loading