.pre-commit-config.yaml 893 B

123456789101112131415161718192021222324252627282930313233343536
  1. fail_fast: true
  2. repos:
  3. - repo: https://github.com/charliermarsh/ruff-pre-commit
  4. rev: v0.7.1
  5. hooks:
  6. - id: ruff-format
  7. args: [reflex, tests]
  8. - id: ruff
  9. args: ["--fix", "--exit-non-zero-on-fix"]
  10. exclude: '^integration/benchmarks/'
  11. # Run pyi check before pyright because pyright can fail if pyi files are wrong.
  12. - repo: local
  13. hooks:
  14. - id: update-pyi-files
  15. name: update-pyi-files
  16. always_run: true
  17. language: system
  18. description: 'Update pyi files as needed'
  19. entry: python3 scripts/make_pyi.py
  20. - repo: https://github.com/RobertCraigie/pyright-python
  21. rev: v1.1.313
  22. hooks:
  23. - id: pyright
  24. args: [reflex, tests]
  25. language: system
  26. - repo: https://github.com/terrencepreilly/darglint
  27. rev: v1.8.1
  28. hooks:
  29. - id: darglint
  30. exclude: '^reflex/reflex.py'