-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathpyproject.toml
108 lines (97 loc) · 3.2 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "FRHEED"
description = "A GUI for real-time RHEED analysis."
license = {file = "LICENSE"}
requires-python = ">=3.10.4, <3.11" # PySpin only supports up to 3.10
authors = [
{ name = "Elliot Young", email = "elliot.young1996@gmail.com" },
]
readme = "README.md"
keywords = [
"rheed",
"gui",
"pyqt",
"scientific",
"imaging",
]
classifiers = [
"Programming Language :: Python :: 3.10",
"License :: OSI Approved :: GNU Affero General Public License v3",
]
dependencies = [
"attrs == 23.2.*",
"matplotlib == 3.8.*",
"numpy == 1.26.*",
"opencv-python == 4.9.0.*",
"platformdirs == 4.2.*",
"PyQt6 == 6.6.1", # QCamera does not work on 6.7.0 on Windows 11
"PyQt6-Qt6 == 6.6.1", # Force to match PyQt6 version otherwise DLL load may fail
"pyqtgraph == 0.13.*",
"scipy == 1.13.*",
]
dynamic = ["version"]
[project.optional-dependencies]
dev = [
"mypy == 1.10.*",
"pytest == 8.2.*",
"ruff == 0.4.3",
"uv == 0.1.39",
]
# TODO(ecyoung3): Add requirements for 3rd-part (e.g. FLIR) cameras (maybe use open source, aravis?)
[project.urls]
Homepage = "https://github.com/ecyoung3/FRHEED"
Repository = "https://github.com/ecyoung3/FRHEED.git"
[tool.hatch.version]
path = "src/frheed/__init__.py"
[tool.hatch.build.targets.sdist]
include = [
"/.github",
]
[tool.hatch.build.targets.wheel]
packages = ["src/frheed"]
[tool.ruff]
# preview = true
line-length = 100
fix = true
[tool.ruff.lint]
select = [
"E", # all pyflakes rules
"F", # all pycodestyle rules
"I", # all isort rules
"TID251", # banned imports, see below
# "PLC0415", # disallow imports outside module top-level scope
]
unfixable = [
"F401", # unused imports
]
[tool.ruff.lint.flake8-tidy-imports.banned-api]
"typing.Callable".msg = "Use `collections.abc.Callable` instead of `typing.Callable`"
"typing.DefaultDict".msg = "Use `collections.defaultdict` instead of `typing.DefaultDict`"
"typing.Dict".msg = "Use the standard library `dict` instead of `typing.Dict`"
"typing.Iterable".msg = "Use `collections.abc.Iterable` instead of `typing.Iterable`"
"typing.Iterator".msg = "Use `collections.abc.Iterator` instead of `typing.Iterator`"
"typing.List".msg = "Use the standard library `list` instead of `typing.List`"
"typing.Optional".msg = "Use the standard library `| None` syntax instead of `typing.Optional`"
"typing.Sequence".msg = "Use `collections.abc.Sequence` instead of `typing.Sequence`"
"typing.Set".msg = "Use the standard library `set` instead of `typing.Set`"
"typing.Tuple".msg = "Use the standard library `tuple` instead of `typing.Tuple`"
"typing.Type".msg = "Use the standard library `type` instead of `typing.Type`"
"typing.Union".msg = "Use the standard library `|` syntax instead of `typing.Union`"
"typing_extensions.Self".msg = "Use `typing.Self` instead of `typing_extensions.Self`"
[tool.mypy]
plugins = ["numpy.typing.mypy_plugin"]
disallow_untyped_defs = true
warn_return_any = true
local_partial_types = true
# Third-party libraries without stubs
[[tool.mypy.overrides]]
module = [
"pyqtgraph",
"PySpin",
"scipy.*",
]
follow_imports = "silent"
ignore_missing_imports = true