fix: 依赖改为可选

This commit is contained in:
duanchao.bill
2022-05-07 10:42:55 +08:00
parent 404cd3c482
commit 998b76bdbf
2 changed files with 31 additions and 5 deletions

25
poetry.lock generated
View File

@@ -459,6 +459,23 @@ type = "legacy"
url = "https://pypi.tuna.tsinghua.edu.cn/simple"
reference = "tsinghua"
[[package]]
name = "pymysql"
version = "1.0.2"
description = "Pure Python MySQL Driver"
category = "main"
optional = true
python-versions = ">=3.6"
[package.extras]
ed25519 = ["PyNaCl (>=1.4.0)"]
rsa = ["cryptography"]
[package.source]
type = "legacy"
url = "https://pypi.tuna.tsinghua.edu.cn/simple"
reference = "tsinghua"
[[package]]
name = "pyparsing"
version = "3.0.7"
@@ -815,12 +832,14 @@ reference = "tsinghua"
[extras]
allure = ["allure-pytest"]
sql = ["sqlalchemy", "pymysql"]
thrift = ["cython", "thrift", "thriftpy2"]
upload = ["requests-toolbelt", "filetype"]
[metadata]
lock-version = "1.1"
python-versions = "^3.7"
content-hash = "15f15916b41e180ee7567716713607183f5d8c8d30300c24dada98be454bc675"
content-hash = "a00de4a66e9c8b73709f339d266be673ca6057dfd4023504677054697611986d"
[metadata.files]
allure-pytest = [
@@ -1195,6 +1214,10 @@ pydantic = [
{file = "pydantic-1.8.2-py3-none-any.whl", hash = "sha256:fec866a0b59f372b7e776f2d7308511784dace622e0992a0b59ea3ccee0ae833"},
{file = "pydantic-1.8.2.tar.gz", hash = "sha256:26464e57ccaafe72b7ad156fdaa4e9b9ef051f69e175dbbb463283000c05ab7b"},
]
pymysql = [
{file = "PyMySQL-1.0.2-py3-none-any.whl", hash = "sha256:41fc3a0c5013d5f039639442321185532e3e2c8924687abe6537de157d403641"},
{file = "PyMySQL-1.0.2.tar.gz", hash = "sha256:816927a350f38d56072aeca5dfb10221fe1dc653745853d30a216637f5d7ad36"},
]
pyparsing = [
{file = "pyparsing-3.0.7-py3-none-any.whl", hash = "sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484"},
{file = "pyparsing-3.0.7.tar.gz", hash = "sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea"},

View File

@@ -45,14 +45,17 @@ filetype = {version = "^1.0.7", optional = true}
Brotli = "^1.0.9"
jinja2 = "^3.0.3"
toml = "^0.10.2"
sqlalchemy = "^1.4.36"
cython = "^0.29.28"
thriftpy2 = "^0.4.14"
thrift = "^0.16.0"
sqlalchemy = {version = "^1.4.36", optional = true}
pymysql = {version = "^1.0.2",optional = true}
cython = {version = "^0.29.28", optional = true}
thriftpy2 = {version = "^0.4.14", optional = true}
thrift = {version = "^0.16.0", optional = true}
[tool.poetry.extras]
allure = ["allure-pytest"] # pip install "httprunner[allure]", poetry install -E allure
upload = ["requests-toolbelt", "filetype"] # pip install "httprunner[upload]", poetry install -E upload
sql = ["sqlalchemy","pymysql"] # pip install "httprunner[sql]", poetry install -E sql
thrift = ["cython","thrift","thriftpy2"] # pip install "httprunner[thrift]", poetry install -E sql
[tool.poetry.dev-dependencies]
coverage = "^4.5.4"