You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

pyproject.toml 2.2 kB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. [tool.uv.workspace]
  2. members = ["packages/*"]
  3. [tool.uv]
  4. dev-dependencies = [
  5. "pyright==1.1.378",
  6. "mypy==1.10.0",
  7. "ruff==0.4.8",
  8. "pytest",
  9. "pytest-asyncio",
  10. "pytest-xdist",
  11. "typer",
  12. "rich",
  13. "polars",
  14. "pytest_mock",
  15. "poethepoet",
  16. "packaging",
  17. "grpcio-tools~=1.62.0",
  18. "mypy-protobuf",
  19. "cookiecutter",
  20. "poethepoet",
  21. "tomli",
  22. ]
  23. [tool.uv.sources]
  24. autogen-core = { workspace = true }
  25. [tool.ruff]
  26. line-length = 120
  27. fix = true
  28. target-version = "py310"
  29. [tool.ruff.format]
  30. docstring-code-format = true
  31. [tool.ruff.lint]
  32. select = ["E", "F", "W", "B", "Q", "I", "ASYNC", "T20"]
  33. ignore = ["F401", "E501"]
  34. [tool.ruff.lint.flake8-tidy-imports]
  35. [tool.ruff.lint.flake8-tidy-imports.banned-api]
  36. "unittest".msg = "Use `pytest` instead."
  37. [tool.mypy]
  38. strict = true
  39. python_version = "3.10"
  40. ignore_missing_imports = true
  41. # from https://blog.wolt.com/engineering/2021/09/30/professional-grade-mypy-configuration/
  42. disallow_untyped_defs = true
  43. no_implicit_optional = true
  44. check_untyped_defs = true
  45. warn_return_any = true
  46. show_error_codes = true
  47. warn_unused_ignores = false
  48. disallow_incomplete_defs = true
  49. disallow_untyped_decorators = true
  50. disallow_any_unimported = true
  51. [tool.pyright]
  52. include = ["src", "tests", "samples"]
  53. typeCheckingMode = "strict"
  54. reportUnnecessaryIsInstance = false
  55. reportMissingTypeStubs = false
  56. exclude = ["src/autogen_core/application/protos"]
  57. [tool.poe.tasks]
  58. fmt = "python run_task_in_pkgs_if_exist.py fmt"
  59. format.ref = "fmt"
  60. lint = "python run_task_in_pkgs_if_exist.py lint"
  61. pyright = "python run_task_in_pkgs_if_exist.py pyright"
  62. mypy = "python run_task_in_pkgs_if_exist.py mypy"
  63. test = "python run_task_in_pkgs_if_exist.py test"
  64. check = ["fmt", "lint", "pyright", "mypy", "test"]
  65. gen-proto = "python -m grpc_tools.protoc --python_out=./packages/autogen-core/src/autogen_core/application/protos --grpc_python_out=./packages/autogen-core/src/autogen_core/application/protos --mypy_out=./packages/autogen-core/src/autogen_core/application/protos --mypy_grpc_out=./packages/autogen-core/src/autogen_core/application/protos --proto_path ../protos/ agent_worker.proto --proto_path ../protos/ cloudevent.proto"