forked from lmstudio-ai/lmstudio-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
141 lines (124 loc) · 4.05 KB
/
Copy pathpyproject.toml
File metadata and controls
141 lines (124 loc) · 4.05 KB
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
[project]
name = "lmstudio"
version = "1.3.0"
description = "LM Studio Python SDK"
authors = [
{name = "LM Studio", email = "team@lmstudio.ai"},
]
maintainers = [
{name = "Alyssa Coghlan", email = "ncoghlan@gmail.com"},
{name = "Christian Zhou-Zheng", email = "christianzhouzheng@gmail.com"},
]
# Note: unless explicitly noted, the actual minimum dependencies may be
# lower than recorded (PDM sets the minimum to the latest version
# available when each dependency is first added to the project).
dependencies = [
"httpx>=0.27.2",
"httpx-ws>=0.7.0",
"msgspec>=0.18.6",
# Minimum msgspec version for 3.13 compatibility
"msgspec>=0.19.0 ; python_version >= '3.13'",
"typing-extensions>=4.12.2",
# Task group handling for versions prior to Python 3.11
"anyio>=4.8.0",
]
# Keep this in sync with the target Python version in sync-sdk-schema.py
requires-python = ">=3.10"
readme = "README.md"
license = "MIT"
license-files = ["LICENSE"]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Typing :: Typed",
]
[project.urls]
# Note: actual URLs are still to be determined
# In particular, the docs url assumes common SDK docs
# with inline parallel examples for each language,
# which may not be how this ends up working.
Homepage = "https://github.com/lmstudio-ai/lmstudio-sdk-python"
Documentation = "https://lmstudio.ai/docs/sdk/"
Issues = "https://github.com/lmstudio-ai/lmstudio-sdk-python/issues"
[build-system]
requires = ["pdm-backend"]
build-backend = "pdm.backend"
[tool.pdm]
distribution = true
[tool.pdm.dev-dependencies]
dev = [
"tox>=4.16.0",
"tox-gh>=1.3.2",
"tox-pdm>=0.7.2",
"pytest>=8.3.1",
"pytest-asyncio>=0.24.0",
"pytest-subtests>=0.13.1",
"ruff>=0.5.4",
"mypy>=1.11.0",
"coverage[toml]>=7.6.4",
]
bootstrap = [
"pdm>=2.16.1",
]
sync-sdk-schema = [
# Needs https://github.com/koxudaxi/datamodel-code-generator/issues/2211 fix
"datamodel-code-generator[http]>=0.26.4",
]
docs = [
# Add markers to avoid trying to lock this group for Python 3.10
# Docs environment will always be Python 3.11 or later
"sphinx>=8.1.3; python_version >= '3.11'",
"sphinx-inline-tabs>=2023.4.21; python_version >= '3.11'",
"furo>=2024.8.6; python_version >= '3.11'",
]
[tool.pytest.ini_options]
# Allow skipping tests that require a local LM Studio instance
addopts = "--strict-markers"
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
"lmstudio: marks tests as needing LM Studio (deselect with '-m \"not lmstudio\"')",
"wip: marks tests as a work-in-progress (select with '-m \"wip\"')"
]
# Warnings should only be emitted when being specifically tested
filterwarnings = [
"error",
"ignore:.*the async API is not yet stable:FutureWarning"
]
# Capture log info from network client libraries
log_format = "%(asctime)s %(levelname)s %(message)s"
log_date_format = "%Y-%m-%d %H:%M:%S"
# Each async test case gets a fresh event loop by default
asyncio_default_fixture_loop_scope = "function"
[tool.coverage.run]
relative_files = true
source_pkgs = [
"lmstudio",
]
source = [
"tests/",
]
[tool.coverage.paths]
source = [
"src/",
"**/.tox/**/site-packages/",
]
[tool.ruff]
# Assume Python 3.10+
target-version = "py310"
[tool.ruff.lint]
# Enable all `pydocstyle` rules, limiting to those that adhere to the
# Google convention via `convention = "google"`, below.
extend-select = ["D"]
# Disable `D105` (it's OK to skip writing docstrings for every magic method)
ignore = ["D105", "D417"]
[tool.ruff.lint.pydocstyle]
# https://sphinxcontrib-napoleon.readthedocs.io/en/latest/example_google.html#example-google
convention = "google"
[tool.ruff.lint.per-file-ignores]
# Skip checking docstrings in the test suite
"tests/**" = ["D"]