modify: PipeConnection 兼容问题
This commit is contained in:
+36
-35
@@ -3,28 +3,28 @@ build-backend = "hatchling.build"
|
||||
requires = ["hatchling"]
|
||||
|
||||
[project]
|
||||
classifiers = [
|
||||
"Development Status :: 3 - Alpha",
|
||||
"Programming Language :: Python :: 3",
|
||||
"Programming Language :: Python :: 3.11",
|
||||
"Programming Language :: Python :: 3.12",
|
||||
"Programming Language :: Python :: 3.13",
|
||||
"Programming Language :: Python :: 3.14",
|
||||
]
|
||||
dependencies = []
|
||||
description = "精细化状态控制的 Python 管道任务控制工具"
|
||||
name = "chongming-task"
|
||||
readme = "README.md"
|
||||
requires-python = ">=3.11"
|
||||
version = "0.1.0"
|
||||
classifiers = [
|
||||
"Development Status :: 3 - Alpha",
|
||||
"Programming Language :: Python :: 3",
|
||||
"Programming Language :: Python :: 3.11",
|
||||
"Programming Language :: Python :: 3.12",
|
||||
"Programming Language :: Python :: 3.13",
|
||||
"Programming Language :: Python :: 3.14",
|
||||
]
|
||||
version = "0.1.1"
|
||||
|
||||
[project.scripts]
|
||||
chongming-task = "chongming_task.cli.main:main"
|
||||
|
||||
[project.optional-dependencies]
|
||||
postgres = [
|
||||
"psycopg-pool>=3.2",
|
||||
"psycopg[binary]>=3.2",
|
||||
"psycopg-pool>=3.2",
|
||||
"psycopg[binary]>=3.2",
|
||||
]
|
||||
|
||||
# 核心包运行时零第三方依赖(CLI 也只用标准库 argparse)。
|
||||
@@ -32,12 +32,13 @@ postgres = [
|
||||
|
||||
[dependency-groups]
|
||||
dev = [
|
||||
"pytest>=8.0",
|
||||
"hypothesis>=6.100",
|
||||
"ruff>=0.6",
|
||||
"mypy>=1.11",
|
||||
"psycopg[binary]>=3.2",
|
||||
"psycopg-pool>=3.2",
|
||||
"pytest>=8.0",
|
||||
"hypothesis>=6.100",
|
||||
"ruff>=0.6",
|
||||
"mypy>=1.11",
|
||||
"psycopg[binary]>=3.2",
|
||||
"psycopg-pool>=3.2",
|
||||
"twine>=7.0.0",
|
||||
]
|
||||
|
||||
[tool.hatch.build.targets.wheel]
|
||||
@@ -49,19 +50,19 @@ packages = ["src/chongming_task"]
|
||||
|
||||
[tool.ruff]
|
||||
line-length = 100
|
||||
target-version = "py311"
|
||||
src = ["src", "tests"]
|
||||
target-version = "py311"
|
||||
# pytest 的临时目录默认落在项目根下,测试往里写的临时 .py 文件不该被 lint 扫到
|
||||
# (其中不乏**故意写坏**的样本,例如"导入一个不存在的依赖")。
|
||||
extend-exclude = ["pytest-of-*"]
|
||||
|
||||
[tool.ruff.lint]
|
||||
select = ["E", "F", "I", "UP", "B", "SIM", "RUF", "C4", "PTH"]
|
||||
ignore = [
|
||||
"RUF001", # 允许注释/字符串中的中文全角标点
|
||||
"RUF002",
|
||||
"RUF003",
|
||||
"RUF001", # 允许注释/字符串中的中文全角标点
|
||||
"RUF002",
|
||||
"RUF003",
|
||||
]
|
||||
select = ["E", "F", "I", "UP", "B", "SIM", "RUF", "C4", "PTH"]
|
||||
|
||||
[tool.ruff.lint.per-file-ignores]
|
||||
"tests/**" = ["B011"]
|
||||
@@ -71,24 +72,24 @@ known-first-party = ["chongming_task"]
|
||||
|
||||
# 内核必须保持可被状态机属性测试穷举验证的纯粹性,故 src 全量 strict。
|
||||
[tool.mypy]
|
||||
python_version = "3.11"
|
||||
strict = true
|
||||
warn_unreachable = true
|
||||
warn_redundant_casts = true
|
||||
show_error_codes = true
|
||||
files = ["src"]
|
||||
python_version = "3.11"
|
||||
show_error_codes = true
|
||||
strict = true
|
||||
warn_redundant_casts = true
|
||||
warn_unreachable = true
|
||||
|
||||
[[tool.mypy.overrides]]
|
||||
module = "tests.*"
|
||||
disallow_untyped_defs = false
|
||||
disallow_incomplete_defs = false
|
||||
disallow_untyped_defs = false
|
||||
module = "tests.*"
|
||||
|
||||
[tool.pytest.ini_options]
|
||||
testpaths = ["tests"]
|
||||
addopts = "-ra --strict-markers --strict-config"
|
||||
markers = [
|
||||
"slow: 耗时较长的集成测试",
|
||||
"windows_only: 仅在 Windows 上有意义的用例",
|
||||
"posix_only: 仅在 POSIX 上有意义的用例",
|
||||
]
|
||||
filterwarnings = ["error"]
|
||||
markers = [
|
||||
"slow: 耗时较长的集成测试",
|
||||
"windows_only: 仅在 Windows 上有意义的用例",
|
||||
"posix_only: 仅在 POSIX 上有意义的用例",
|
||||
]
|
||||
testpaths = ["tests"]
|
||||
|
||||
Reference in New Issue
Block a user