-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
153 lines (132 loc) · 5.21 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
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
# https://packaging.python.org/en/latest/specifications/pyproject-toml/#pyproject-toml-spec
# https://flit.pypa.io/en/latest/pyproject_toml.html
[build-system]
requires = ["flit_core >=3.2,<4"]
build-backend = "flit_core.buildapi"
[project]
name = "open-exchange"
authors = [{ name = "Open Exchange Labs, Inc.", email = "[email protected]" }]
readme = "README.md"
license = { file = "LICENSE.md" }
classifiers = [
"Development Status :: 3 - Alpha",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"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",
"Programming Language :: Python :: 3.12",
"Intended Audience :: Developers",
"Intended Audience :: Information Technology",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dynamic = ["version", "description"]
requires-python = ">=3.6.2,<4.0.0"
dependencies = [
"cached-property>=1.5.2; python_version<'3.8'",
"pydantic>=1.9.2",
"requests>=2.27.1",
"urllib3>=1.21.1",
]
[project.urls]
Home = "https://github.com/opendoor-labs/open-exchange-python"
[tool.poetry]
# Use Poetry only for dependency management, not packaging.
package-mode = false
name = "open-exchange"
description = "Open Exchange Python SDK"
authors = ["Open Exchange Labs, Inc. <[email protected]>"]
[tool.poetry.dependencies]
python = "^3.6.2, <4.0.0"
cached-property = { version = "^1.5.2", python = "<3.8" } # Included in the standard library in Python 3.8+
pydantic = "^1.9.2"
requests = "^2.27.1"
urllib3 = "^1.21.1"
[tool.poetry.group.dev.dependencies]
black = ">=22.8.0" # Ruff requires Python >=3.7
flake8 = ">=5.0.4"
flit = "^3.9.0"
isort = ">=5.10.1" # Ruff requires Python >=3.7
mypy = ">0.1"
pytest = "^7.0.1"
types-requests = "^2.31.0.5"
types-urllib3 = "^1.26.25.14"
[tool.black]
# https://black.readthedocs.io/en/stable/usage_and_configuration/the_basics.html
line-length = 120
target-version = ["py36"] # Python 3.6
skip-string-normalization = false # Change to single quotes when we switch to Ruff.
[tool.isort]
# https://pycqa.github.io/isort/docs/configuration/options.html
color_output = true
known_first_party = ["opendoor"] # Is Opendoor a first party or 3rd party?
line_length = 120
profile = "black"
py_version = 36 # Python 3.6
remove_redundant_aliases = true
skip_gitignore = true
import_heading_stdlib = "Standard Library"
import_heading_thirdparty = "Third-Party Libraries"
import_heading_firstparty = "1st Party Libraries"
import_heading_localfolder = "Local Folder"
# Consistenly use PEP 563-style annotations, avoids common confusion and issues.
# add_imports = ["from __future__ import annotations"] # TODO: Enable this once we're on Python 3.7+
force_adds = true
[tool.mypy]
python_version = "3.6"
incremental = true
show_column_numbers = true
check_untyped_defs = true
disallow_any_explicit = true
disallow_any_unimported = true
disallow_incomplete_defs = true
disallow_subclassing_any = true
disallow_untyped_calls = true
# disallow_untyped_decorators = true # Consider enabling this in the future.
disallow_untyped_defs = true
no_implicit_reexport = true
raise_exceptions = true
scripts_are_modules = true
show_traceback = true
strict_equality = true
warn_no_return = true
warn_redundant_casts=true
# warn_return_any = true # Consider enabling this in the future.
warn_unreachable = true
warn_unused_configs = true
warn_unused_ignores = true
# ------------------------------------------------------------------
# Future mypy flags to potentially enable system-wide or per-module.
# (each are already false by default).
# ------------------------------------------------------------------
# This flag disallows functions that have Any in their signature after
# decorator transformation.
disallow_any_decorated = false
# This flag disallows usage of generic types that do not specify explicit type
# parameters. For example, you can’t use a bare x: list. Instead, you must
# always write something like x: list[int].
disallow_any_generics = false
# This flag disallows all expressions in the module that have type Any. If an
# expression of type Any appears anywhere in the module mypy will output an
# error unless the expression is immediately used as an argument to cast() or
# assigned to a variable with an explicit type annotation.
#
# In addition, declaring a variable of type Any or casting to type Any is not
# allowed. Note that calling functions that take parameters of type Any is still allowed.
disallow_any_expr = false
[[tool.mypy.overrides]]
# We might want to follow Mypy's instructions for producing our own stub files
# to have type checking for the following modules.
module = [
'cached_property.*',
]
# Suppresses "missing library stubs or py.typed marker" errors. The imported
# module will continue to be of type Any (no type checking).
# https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-library-stubs-or-py-typed-marker
ignore_missing_imports = true