forked from MADRAS-crowds/madras-data-app
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
30 additions
and
20 deletions.
There are no files selected for viewing
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 |
---|---|---|
@@ -1,3 +1,4 @@ | ||
|
||
name: madras-data-app | ||
|
||
on: | ||
|
@@ -13,25 +14,28 @@ jobs: | |
streamlit: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.11' | ||
- uses: streamlit/[email protected] | ||
with: | ||
app-path: app.py | ||
ruff: true | ||
|
||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install black mypy ruff | ||
pip install -r requirements.txt | ||
python -m pip install --upgrade pip --quiet | ||
pip install -r requirements.txt --quiet | ||
pip install mypy ruff --quiet | ||
- name: Lint with Ruff | ||
run: ruff . | ||
- name: Format with Black | ||
run: | | ||
black --diff $(git ls-files '*.py') | ||
- name: Analysing with Mypy | ||
run: | | ||
mypy --strict $(git ls-files '*.py') | ||
run: ruff check . | ||
|
||
- name: Analyze with Mypy | ||
run: mypy --strict --jobs 4 $(git ls-files '*.py') | ||
|
||
- name: Run Streamlit app | ||
uses: streamlit/[email protected] | ||
with: | ||
app-path: app.py | ||
ruff: true |
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 |
---|---|---|
@@ -1,5 +1,11 @@ | ||
line-length = 180 | ||
target-version = "py311" | ||
lint.select = ["E", "W", "F", "C", "R"] | ||
lint.ignore = ["E501"] | ||
# --extend-ignore = "E203, W503" | ||
|
||
# Linting rule selection | ||
select = ["E", "W", "F", "C", "R"] | ||
ignore = ["E501"] # Ignore long line errors | ||
|
||
# Exclude files from checks | ||
exclude = [ | ||
"**/*.ipynb" | ||
] |