Files
group_fqcd_jr/pyproject.toml
T
张胜宇 f68b052a69 fix: 端点编号去重与 milvus-lite 降为可选依赖
按 qyqy 在 PR #7 评审中的要求处理两项:

- docs/05-接口文档.md §19:客服画像候选的两个端点由 A034/A035 改为 A039/A040。
  原编号与 qyqy 侧登录 / RBAC 只读接口(A034-A038)重复;docs 守卫脚本只校验
  文档文件名编号、不校验 §19 端点编号,因此该重复会静默遗留。改后全表 55 个
  端点编号唯一。
- pyproject.toml / requirements.txt:milvus-lite 由主 dependencies 挪到
  [project.optional-dependencies] dev;requirements.txt 只保留说明性注释,
  不再作为生效依赖。理由:它仅用于本地开发(Docker Milvus 未运行时的本地
  持久化向量库),进主依赖会让生产环境多背一个包。

验证:pytest tests/unit tests/contract -> 1275 passed, 2 skipped, 0 failed;
ruff check app tests tools alembic 通过;mypy app 通过(244 个源文件)。
2026-09-12 11:53:35 +08:00

86 lines
2.5 KiB
TOML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
[build-system]
requires = ["setuptools>=75"]
build-backend = "setuptools.build_meta"
[project]
name = "jr-agent-platform"
version = "0.1.0"
description = "金融系统 Agent 通用底座"
requires-python = ">=3.13,<3.14"
dependencies = [
"fastapi>=0.115,<1",
"uvicorn[standard]>=0.34,<1",
"pydantic>=2.10,<3",
"pydantic-settings>=2.7,<3",
"python-dotenv>=1.0,<2",
"greenlet>=3.1,<4",
"sqlalchemy>=2.0,<3",
"alembic>=1.14,<2",
"asyncmy>=0.2,<1",
"pymysql>=1.1,<2",
"redis>=5.2,<6",
"neo4j>=5.28,<6",
"pymilvus>=2.5,<3",
"PyJWT>=2.10,<3",
"cryptography>=44,<51",
"bcrypt>=4.0,<5",
"httpx>=0.28,<1",
"tzdata>=2025.1,<2027",
"alibabacloud_docmind_api20220711==1.4.14",
"alibabacloud_tea_openapi>=0.4.3,<1",
"alibabacloud_tea_util>=0.3.13,<1",
"alibabacloud_credentials>=1.0.2,<2",
"python-pptx>=1.0,<2",
"python-docx>=1.1,<2",
"openpyxl>=3.1,<4",
"Pillow>=10,<12",
"matplotlib>=3.9,<4",
"python-multipart>=0.0.20,<1",
]
[project.optional-dependencies]
dev = [
"pytest>=8.3,<9",
"pytest-asyncio>=0.25,<1",
"aiosqlite>=0.20,<1",
"ruff>=0.9,<1",
"mypy>=1.14,<2",
# 测试用:场外邮件 Worker 等用例走 SQLAlchemy 的 SQLite 内存库。
# 原先没声明 —— 别人的环境装完依赖跑测试,这 6 个用例会直接
# ModuleNotFoundError: No module named 'aiosqlite'。
"aiosqlite>=0.20,<1",
# 本地开发专用:Docker Milvus 未运行时用的本地持久化向量库
# (配合 `.env` 的 `MILVUS_LOCAL_URI` 使用)。
# 刻意**不**进主 `dependencies`:团队/生产环境使用受管 Milvus,
# 多背这个包没有意义,而它还正是 `MILVUS_LOCAL_URI` 那个坑的来源。
"milvus-lite>=3.2,<4",
]
[tool.setuptools.packages.find]
include = ["app*"]
[tool.pytest.ini_options]
testpaths = ["tests"]
asyncio_mode = "auto"
asyncio_default_fixture_loop_scope = "function"
markers = ["integration: requires local database services"]
# 临时目录的落点由 `tests/conftest.py` 覆盖 `tmp_path` 决定(落在仓库内 `.workdir/pytest-tmp`)。
# 这里**不**写 `basetemp`:pytest 只在命令行认它,写在 ini 里会被静默忽略(实测无效),
# 留着会让人误以为已经配好了。系统临时目录权限坏掉的原因与修法见 conftest 的说明。
[tool.ruff]
line-length = 100
target-version = "py313"
[tool.ruff.lint]
select = ["E", "F", "I", "B", "UP"]
[tool.ruff.lint.per-file-ignores]
"alembic/versions/*.py" = ["E501"]
"tools/*.py" = ["E501", "I001", "B007"]
[tool.mypy]
python_version = "3.13"
strict = true
packages = ["app"]