-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor codebase to apply selected ruff linting and formatting rules (…
…#311) * add ruff linting and formatting rules * basic ruff autofix * update pyproject * refactor utils.py * refactoring modules for ruff linting * Add ruff linting formatting and basic ruff autofixes (#305) * add ruff linting and formatting rules * basic ruff autofix * lint / black * bump version --------- Co-authored-by: Niall Keleher <[email protected]> * update readme (#308) * update readme * update readme * fix typo * more readme udpates * update pyfixest.qmd * only return md table in readme * dont return rwolf output in readme * attempt to print data frame * add examples for rwolf * add examples for rwolf * fix small typos * add bonferroni correction #309 (#310) * add bonferroni correction #309 * Update rwolf and bonferroni docs * update version to 0.15.4 * basic ruff autofix * order imports * basic ruff autofix * Add ruff linting formatting and basic ruff autofixes (#305) * add ruff linting and formatting rules * basic ruff autofix * lint / black * bump version --------- Co-authored-by: Niall Keleher <[email protected]> * add black pre-commit hook * refactoring modules for ruff linting * add ruff to linting github action * disable ruff on notebooks * format FormulaParser * temp - run tests on fix-linting-errors * fix dataframe filtering, noqa: E712 * fix dropped_singleton_bool conditional * remove extra debugging branch on CI --------- Co-authored-by: Alexander Fischer <[email protected]>
- Loading branch information
Showing
44 changed files
with
965 additions
and
812 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: Lint | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.11" | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install ruff | ||
- name: Run Ruff | ||
run: ruff check --output-format=github . | ||
- name: Run Black | ||
uses: psf/black@stable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# docs: justfile docs: https://just.systems/man/en/ | ||
default: | ||
just --list --unsorted | ||
|
||
# Clean environment | ||
[confirm] | ||
clean: | ||
rm -rf .venv/ | ||
|
||
# Update dependencies in pyproject.toml | ||
poetry-update: | ||
poetry update | ||
|
||
# Install development dependencies | ||
install-dev: | ||
poetry env use 3.11 | ||
poetry config virtualenvs.in-project true | ||
poetry install | ||
|
||
# Install R dependencies | ||
install-r: | ||
Rscript -e 'install.packages(c("broom", "clubSandwich", "did2s", "fixest", "wildrwolf"), repos="https://cran.rstudio.com")' | ||
|
||
# Run pytest | ||
tests: | ||
poetry run pytest -n 4 --cov-report=term tests | ||
|
||
# Build the package | ||
build: tests | ||
poetry build | ||
|
||
# Build documentation and website | ||
docs-build: | ||
poetry run quartodoc build --verbose --config docs/_quarto.yml | ||
|
||
# Render documentation and website | ||
render: docs-build | ||
poetry run quarto render docs | ||
|
||
# Build the documentation and watch for changes | ||
docs-watch: | ||
poetry run poetry run quartodoc build --watch --verbose --config docs/_quarto.yml | ||
|
||
# Preview the docs | ||
preview: | ||
poetry run quarto preview docs | ||
|
||
# Clean docs build | ||
docs-clean: | ||
rm -rf docs/_build docs/api/api_card |
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.