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

Metadata overhaul #120

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
1 change: 0 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ on:

env:
PACKAGE_NAME: lyse
SCM_LOCAL_SCHEME: no-local-version
ANACONDA_USER: labscript-suite

# Configuration for a package with compiled extensions:
Expand Down
22 changes: 14 additions & 8 deletions lyse/__version__.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,25 @@
import os
from pathlib import Path
try:
import importlib.metadata as importlib_metadata
except ImportError:
import importlib_metadata

VERSION_SCHEME = {
"version_scheme": os.getenv("SCM_VERSION_SCHEME", "release-branch-semver"),
"local_scheme": os.getenv("SCM_LOCAL_SCHEME", "node-and-date"),
}

root = Path(__file__).parent.parent
if (root / '.git').is_dir():
from setuptools_scm import get_version
__version__ = get_version(root, **VERSION_SCHEME)
try:
from setuptools_scm import get_version
VERSION_SCHEME = {
"version_scheme": "release-branch-semver",
"local_scheme": "node-and-date",
}
scm_version = get_version(root, **VERSION_SCHEME)
except ImportError:
scm_version = None
else:
scm_version = None

if scm_version is not None:
__version__ = scm_version
else:
try:
__version__ = importlib_metadata.version(__package__)
Expand Down
71 changes: 70 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,73 @@
requires = ["setuptools>=64", "wheel", "setuptools_scm>=8"]
build-backend = "setuptools.build_meta"

[tool.setuptools_scm]
[tool.setuptools_scm]
version_scheme = "release-branch-semver"
local_scheme = "no-local-version"

[tool.setuptools]
zip-safe = false
include-package-data = true

[tool.setuptools.packages]
find = {namespaces = false}


[project]
name = "lyse"
description = "Automated analysis queue for labscript suite experiments"
authors = [
{name = "The labscript suite community", email = "labscriptsuite@googlegroups.com"},
]
keywords = ["experiment control", "automation"]
license = {file = 'LICENSE.txt'}
classifiers = [
"License :: OSI Approved :: BSD License",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
]
requires-python = ">=3.6"
dependencies = [
"desktop-app>=0.1.2",
"h5py",
"importlib_metadata",
"labscript_utils>=3.3.0",
"matplotlib",
"numpy",
"pandas>=0.21",
"qtutils>=2.2.2",
"scipy",
"tzlocal",
"zprocess>=2.2.2",
]
dynamic = ["version"]

[project.readme]
file = "README.md"
content-type = "text/markdown"

[project.urls]
Homepage = "http://labscriptsuite.org/"
Documentation = "https://docs.labscriptsuite.org/"
Repository = "https://github.com/labscript-suite/lyse/"
Downloads = "https://github.com/labscript-suite/lyse/releases/"
Tracker = "https://github.com/labscript-suite/lyse/issues/"

[project.optional-dependencies]
docs = [
"PyQt5",
"Sphinx==7.2.6",
"sphinx-rtd-theme==2.0.0",
"myst_parser==2.0.0",
]

[project.scripts]
lyse = "desktop_app:entry_point"

[project.gui-scripts]
lyse-gui = "desktop_app:entry_point"
55 changes: 0 additions & 55 deletions setup.cfg

This file was deleted.

9 changes: 0 additions & 9 deletions setup.py

This file was deleted.