-
Notifications
You must be signed in to change notification settings - Fork 124
Expand file tree
/
Copy pathpyproject.toml
More file actions
147 lines (135 loc) · 4.59 KB
/
pyproject.toml
File metadata and controls
147 lines (135 loc) · 4.59 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
142
143
144
145
146
147
[build-system]
requires = ["maturin>=1.0,<2.0"]
build-backend = "maturin"
[project]
name = "pinecone"
version = "9.0.0"
description = "Pinecone Python SDK"
readme = "README.md"
license = "Apache-2.0"
requires-python = ">=3.10"
authors = [
{ name = "Pinecone Systems, Inc.", email = "support@pinecone.io" },
]
keywords = ["Pinecone", "vector", "database", "cloud", "RAG", "AI"]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: Information Technology",
"Intended Audience :: Science/Research",
"Intended Audience :: System Administrators",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Database",
"Topic :: Software Development",
"Topic :: Software Development :: Libraries",
"Topic :: Software Development :: Libraries :: Application Frameworks",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
# Upper-bound httpx to exclude the 1.0 pre-release line (1.0.devN), which
# drops symbols (e.g. httpx.BaseTransport) the SDK relies on. Without this
# cap, `pip install --pre pinecone` resolves httpx to a broken pre-release.
"httpx[http2]>=0.27,<1.0",
"msgspec",
"orjson",
]
[project.optional-dependencies]
dev = [
"pytest",
"pytest-asyncio",
"pytest-timeout",
"respx",
"mypy",
"ruff",
]
docs = [
"sphinx>=8.0",
"furo",
"myst-parser>=4.0",
"sphinx-copybutton",
"sphinx-tabs",
]
[project.urls]
Homepage = "https://www.pinecone.io"
Documentation = "https://docs.pinecone.io"
Source = "https://github.com/pinecone-io/python-sdk"
Issues = "https://github.com/pinecone-io/python-sdk/issues"
[tool.maturin]
manifest-path = "rust/Cargo.toml"
module-name = "pinecone._grpc"
python-source = "."
# maturin 1.7.x doesn't auto-include the LICENSE file in the sdist even though
# it adds `License-File: LICENSE` to PKG-INFO from the SPDX license expression.
# The mismatch makes PyPI reject the sdist. Explicit include fixes both forms.
include = ["LICENSE"]
[tool.mypy]
strict = true
python_version = "3.10"
[tool.ruff]
line-length = 100
target-version = "py310"
[tool.ruff.lint]
select = ["E", "F", "I", "W", "UP", "B", "ASYNC", "S", "T20", "N", "C4", "SIM", "PERF", "RUF", "PT", "TID", "RET", "FURB"]
ignore = ["ASYNC109", "SIM108", "PERF203", "RUF002"]
[tool.ruff.lint.flake8-tidy-imports.banned-api]
"requests".msg = "Use httpx instead of requests"
"pydantic".msg = "Use msgspec instead of pydantic"
[tool.ruff.lint.isort]
required-imports = ["from __future__ import annotations"]
[tool.ruff.lint.per-file-ignores]
"tests/**" = [
"E501",
"B905",
"S101",
"S105",
"S106",
"S107",
"S110",
"T20",
"PT018",
"PT019",
# Stylistic rules whose suggestions don't fit common test patterns:
"B017", # pytest.raises(Exception) is sometimes legitimately broad in tests
"B018", # "useless" attribute access used to trigger AttributeError
"PT006", # parametrize tuple/list form — both readable
"PT011", # pytest.raises(Exception) too broad — duplicate of B017 stylistically
"PT017", # assertion on exception in `except` block — common test pattern
"SIM117", # nested `with` — often clearer than combined when scopes differ
"SIM105", # try/except/pass — fine in test cleanup paths
"PERF401", # list-comprehension perf doesn't matter in tests
"ASYNC240", # os.path in async functions — fine in tests; not real async I/O
]
"docs/**" = ["E501"]
"scripts/**" = [
"T201", # print() is fine in CLI utilities
"S603", # subprocess.run with hardcoded args is trusted in our scripts
"S607", # invoking `cargo` / `git` by partial path is intentional
]
"pinecone/_internal/http_client.py" = ["S311"]
"pinecone/grpc/future.py" = ["S110", "SIM105"]
[tool.pytest.ini_options]
anyio_mode = "auto"
timeout = 5
markers = [
"smoke: end-to-end smoke tests that hit a real Pinecone backend (see tests/smoke/README.md)",
"integration: real-API integration tests against a live Pinecone backend",
"preview_integration: real-API tests against 2026-01.alpha preview endpoints (not CI-gating)",
]
[dependency-groups]
dev = [
"anyio>=4.13.0",
"ipykernel>=7.2.0",
"pytest>=9.0.3",
"pytest-anyio>=0.0.0",
"pytest-asyncio>=0.23",
"python-dotenv>=1.2.2",
"pytest-benchmark>=5.0.0",
"pytest-xdist>=3.6",
"respx>=0.22.0",
"mypy>=1.20.0",
"ruff>=0.15.9",
]