Skip to content

Commit c60df86

Browse files
authored
[tools] convert project metadata to PEP 621 pyproject.toml (#112)
Signed-off-by: Antoine MAZEAS <[email protected]>
1 parent 34eb22b commit c60df86

File tree

5 files changed

+74
-106
lines changed

5 files changed

+74
-106
lines changed

.circleci/config.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
- checkout
1212
- run:
1313
name: install dependencies
14-
command: pip3 install -r requirements.txt -r test-requirements.txt --user
14+
command: pip3 install --user .[dev]
1515
- run:
1616
name: confirm black version
1717
command: black --version
@@ -33,7 +33,7 @@ jobs:
3333
- checkout
3434
- run:
3535
name: install dependencies
36-
command: pip3 install -r requirements.txt --user
36+
command: pip3 install --user .
3737
- run:
3838
name: run tests
3939
command: python -m unittest
@@ -60,7 +60,7 @@ jobs:
6060
- run:
6161
name: install dependencies
6262
command: >
63-
pip3 install --user -r requirements.txt -r test-requirements.txt
63+
pip3 install --user .[dev]
6464
- run:
6565
name: check version
6666
command: |
@@ -92,7 +92,7 @@ jobs:
9292
at: ~/openbas-client
9393
- run:
9494
name: install dependencies
95-
command: pip3 install -r requirements.txt --user
95+
command: pip3 install --user .
9696
- run:
9797
name: install twine
9898
command: pip3 install twine

pyproject.toml

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,77 @@
1+
[project]
2+
name = "pyobas"
3+
dynamic = ["version"]
4+
description = "Python API client for OpenBAS."
5+
authors = [
6+
{name = "Filigran", email = "[email protected]"}
7+
]
8+
maintainers = [
9+
{name = "Filigran", email = "[email protected]"}
10+
]
11+
license = { text = "Apache-2.0" }
12+
readme = "README.md"
13+
requires-python = ">=3.11"
14+
classifiers = [
15+
"Development Status :: 5 - Production/Stable",
16+
"Intended Audience :: Developers",
17+
"Intended Audience :: Information Technology",
18+
"Intended Audience :: Science/Research",
19+
"License :: OSI Approved :: Apache Software License",
20+
"Natural Language :: English",
21+
"Natural Language :: French",
22+
"Operating System :: OS Independent",
23+
"Programming Language :: Python :: 3",
24+
"Topic :: Security",
25+
"Topic :: Software Development :: Libraries :: Python Modules"
26+
]
27+
dependencies = [
28+
"datefinder (>=0.7.3,<0.8)",
29+
"pika (>=1.3.0,<1.4.0)",
30+
"python-magic (>=0.4.27,<0.5); sys_platform == 'linux' or sys_platform == 'darwin'",
31+
"python-magic-bin (>=0.4.14,<0.5); sys_platform == 'win32'",
32+
"python_json_logger (>=3.3.0,<3.4.0)",
33+
"PyYAML (>=6.0,<6.1)",
34+
"pydantic (>=2.11.3,<2.12.0)",
35+
"requests (>=2.32.3,<2.33.0)",
36+
"setuptools (>=80.4.0,<80.5.0)",
37+
"cachetools (>=5.5.0,<5.6.0)",
38+
"prometheus-client (>=0.21.1,<0.22.0)",
39+
"opentelemetry-api (>=1.32.0,<1.33.0)",
40+
"opentelemetry-sdk (>=1.32.0,<1.33.0)",
41+
# OpenBAS,
42+
"requests-toolbelt (>=1.0.0,<1.1.0)",
43+
"dataclasses-json (>=0.6.4,<0.7.0)",
44+
"thefuzz (>=0.22,<0.23)"
45+
]
46+
47+
[project.optional-dependencies]
48+
dev = [
49+
"black (>=25.1.0,<25.2.0)",
50+
"build (>=1.2.1,<1.3.0)",
51+
"isort (>=6.0.0,<6.1.0)",
52+
"types-pytz (>=2025.2.0.20250326,<2025.3.0.0)",
53+
"pre-commit (>=4.2.0,<4.3.0)",
54+
"types-python-dateutil (>=2.9.0,<2.10.0)",
55+
"wheel (>=0.45.1,<0.46.0)"
56+
]
57+
doc = [
58+
"autoapi (>=2.0.1,<2.1.0)",
59+
"sphinx-autodoc-typehints (>=3.2.0,<3.3.0)",
60+
"sphinx-rtd-theme (>=3.0.2,<3.1.0)"
61+
]
62+
163
[build-system]
264
requires = ["setuptools", "wheel"]
365
build-backend = "setuptools.build_meta"
466

67+
[tool.setuptools]
68+
include-package-data = true
69+
70+
[tool.setuptools.packages.find]
71+
72+
[tool.setuptools.dynamic]
73+
version = { attr = "pyobas.__version__" }
74+
575
[tool.isort]
676
profile = "black"
777

requirements.txt

Lines changed: 0 additions & 18 deletions
This file was deleted.

setup.cfg

Lines changed: 0 additions & 71 deletions
This file was deleted.

test-requirements.txt

Lines changed: 0 additions & 13 deletions
This file was deleted.

0 commit comments

Comments
 (0)