docsifer / pyproject.toml
lamhieu's picture
deps: bump to Gradio 5 + FastAPI 0.115 stack (mirror lightweight-embeddings)
80eaaf7
[build-system]
requires = ["poetry-core>=1.6.0"]
build-backend = "poetry.core.masonry.api"
[tool.poetry]
name = "docsifer"
version = "1.1.0"
description = "Convert PDF, PPT, Word, Excel, images, audio, HTML, JSON, CSV, XML, ZIP and more to Markdown โ€” with optional LLM enhancement."
authors = ["Hieu Lam <lamhieu.vk@gmail.com>"]
readme = "README.md"
homepage = "https://github.com/lh0x00/docsifer"
repository = "https://github.com/lh0x00/docsifer"
license = "MIT"
packages = [{ include = "docsifer" }]
[tool.poetry.dependencies]
python = "^3.10"
# Runtime stack aligned with ``lightweight-embeddings`` for clean Gradio /
# FastAPI / Starlette / Pydantic / Jinja2 interop on Hugging Face Spaces.
fastapi = ">=0.115,<0.120"
uvicorn = { version = ">=0.30,<0.40", extras = ["standard"] }
pydantic = ">=2.7,<3.0"
pydantic-settings = ">=2.4,<3.0"
orjson = ">=3.10,<4.0"
python-multipart = ">=0.0.9"
httpx = { version = ">=0.27,<0.30", extras = ["http2"] }
openai = ">=1.40,<2.0"
tiktoken = ">=0.7,<1.0"
markitdown = "0.0.1a3"
selectolax = ">=0.3.21"
python-magic = "0.4.27"
upstash-redis = ">=1.2,<2.0"
cachetools = ">=5.3,<6.0"
psutil = ">=5.9,<8.0"
Pillow = ">=10.3,<12.0"
requests = ">=2.31,<3.0"
# Gradio 5.x is required for compatibility with modern Starlette templating;
# Gradio 4.x calls ``TemplateResponse`` with a deprecated signature.
gradio = { version = ">=5.0,<6.0", optional = true }
pandas = { version = ">=2.0,<3.0", optional = true }
[tool.poetry.extras]
ui = ["gradio", "pandas"]
[tool.poetry.group.dev.dependencies]
pytest = ">=8.0,<9.0"
pytest-asyncio = ">=0.23,<1.0"
ruff = ">=0.6,<1.0"
mypy = ">=1.10,<2.0"
types-requests = "*"
fakeredis = ">=2.23,<3.0"
# ---------------------------------------------------------------------------
# Tooling
# ---------------------------------------------------------------------------
[tool.ruff]
line-length = 100
target-version = "py310"
extend-exclude = ["poetry.lock"]
[tool.ruff.lint]
select = [
"E", "F", "W", # pycodestyle / pyflakes
"I", # isort
"B", # flake8-bugbear
"UP", # pyupgrade
"SIM", # simplify
"RET", # flake8-return
"C4", # comprehensions
"ASYNC", # async best practices
]
ignore = [
"E501", # line length handled by formatter
"B008", # FastAPI Depends() in defaults is idiomatic
]
[tool.ruff.lint.per-file-ignores]
"tests/**" = ["B011", "S101"]
[tool.ruff.format]
quote-style = "double"
[tool.mypy]
python_version = "3.10"
warn_unused_configs = true
warn_redundant_casts = true
warn_unused_ignores = true
disallow_untyped_defs = false
ignore_missing_imports = true
files = ["docsifer"]
[[tool.mypy.overrides]]
module = ["docsifer.core.*", "docsifer.analytics.*", "docsifer.safety.*"]
disallow_untyped_defs = true
[tool.pytest.ini_options]
asyncio_mode = "auto"
testpaths = ["tests"]
filterwarnings = [
"ignore::DeprecationWarning",
]