Skip to content

Commit

Permalink
Migrate setup.py to pyproject.toml
Browse files Browse the repository at this point in the history
  • Loading branch information
tsundvoll committed Jun 3, 2024
1 parent 0aafeb3 commit e2844e5
Show file tree
Hide file tree
Showing 4 changed files with 79 additions and 107 deletions.
77 changes: 77 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,81 @@
requires = ["setuptools>=64.0", "setuptools_scm>=8"]
build-backend = "setuptools.build_meta"

[project]
name = "isar"
authors = [{ name = "Equinor ASA", email = "[email protected]" }]
description = "Integration and Supervisory control of Autonomous Robots"
readme = "README.md"
requires-python = ">=3.11"
license = { file = "LICENSE" }
classifiers = [
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: Eclipse Public License 2.0 (EPL-2.0)",
"Natural Language :: English",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Physics",
"Topic :: Software Development :: Libraries",
]
dependencies = [
"alitra>=1.1.3",
"azure-identity",
"azure-keyvault-secrets",
"azure-storage-blob",
"backoff",
"click",
"dacite",
"fastapi-azure-auth",
"fastapi",
"injector",
"numpy",
"opencensus-ext-azure",
"opencensus-ext-logging",
"opencensus-ext-requests",
"paho-mqtt",
"pydantic_settings",
"pydantic",
"PyJWT",
"python-dotenv",
"PyYAML",
"requests-toolbelt",
"requests",
"transitions",
"uvicorn",
]
dynamic = ["version"]

[project.urls]
repository = "https://github.com/equinor/isar.git"

[project.optional-dependencies]
dev = [
"black",
"flake8",
"mypy",
"myst-parser",
"pre-commit",
"pytest-dotenv",
"pytest-mock",
"pytest-xdist",
"pytest",
"requests-mock",
"sphinx",
]

[tool.setuptools_scm]
# This section is empty but required for dynamic versioning.

[tool.mypy]
no_strict_optional = true
no_site_packages = true
ignore_missing_imports = true
exclude = ["build"]
files = ["src", "tests"]

[tool.pytest.ini_options]
testpaths = ["tests"]
log_cli = true
32 changes: 0 additions & 32 deletions setup.cfg

This file was deleted.

70 changes: 0 additions & 70 deletions setup.py

This file was deleted.

7 changes: 2 additions & 5 deletions src/isar/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
from importlib.metadata import PackageNotFoundError, distribution
from importlib.metadata import version

try:
__version__ = distribution(__name__).version
except PackageNotFoundError:
pass # package is not installed
__version__ = version(__package__ or __name__)

0 comments on commit e2844e5

Please sign in to comment.