Skip to content
This repository was archived by the owner on Dec 18, 2023. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 24 additions & 3 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,26 +13,47 @@ jobs:
fail-fast: false
matrix:
python-version: [3.7]
defaults:
run:
# https://github.com/conda-incubator/setup-miniconda/tree/v2#use-a-default-shell
shell: bash -l {0}

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
- name: Set up Miniconda with Python ${{ matrix.python-version }}
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
miniconda-version: "latest"
python-version: ${{ matrix.python-version }}
activate-environment: test_env

- name: Install linters
run: |
python -m pip install --upgrade pip
python -m pip install black==22.3.0 flake8==4.0.1 libcst==0.4.1 ufmt==1.3.2 usort==1.0.2
VERSION=$(grep "version" .pyre_configuration | sed -n -e 's/.*\(0\.0\.[0-9]*\).*/\1/p')
pip install pyre-check-nightly==$VERSION

- name: Print out package info to help with debug
- name: Print out linter package info to help with debug
run: pip list

- name: Lint with flake8
run: flake8 .

- name: Lint with ufmt (black + usort)
run: ufmt check .

- name: Install dependencies (for Pyre)
run: |
conda install -c conda-forge -y boost-cpp eigen=3.4.0
pip install torch --extra-index-url https://download.pytorch.org/whl/cpu
pip install -v -e .[dev]

- name: Print out pyre package info to help with debug
run: pip list

- name: Run Pyre
run: pyre
12 changes: 12 additions & 0 deletions .pyre_configuration
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"site_package_search_strategy": "all",
"search_path": [
{
"site-package": "beanmachine"
}
],
"source_directories": [
"./src"
],
"version": "0.0.101665573068"
}