Fixing lints and warning from utils files #998
This file contains hidden or 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
name: build | |
on: | |
pull_request: | |
types: [opened, synchronize] | |
push: | |
branches: [master] | |
jobs: | |
fmt: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/[email protected] | |
- name: Format files | |
run: make dev fmt | |
- name: Fail on differences | |
run: git diff --exit-code | |
tests: | |
# Ubuntu latest no longer installs Python 3.9 by default so install it | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/[email protected] | |
with: | |
fetch-depth: 0 | |
# - name: Cache packages | |
# uses: actions/cache@v2 | |
# with: | |
# path: | | |
# ~/go/pkg/mod | |
# ~/.cache/go-build | |
# vendor | |
# key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }} | |
# restore-keys: | | |
# ${{ runner.os }}-go- | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'temurin' # Can also use 'zulu', 'adopt', etc. | |
java-version: '17' | |
- name: Get Java version | |
run: java -version | |
#- name: Set Java 8 | |
# run: | | |
# sudo update-alternatives --set java /usr/lib/jvm/temurin-8-jdk-amd64/bin/java | |
# java -version | |
- name: Install Python | |
uses: actions/setup-python@v5 | |
with: | |
cache: 'pip' | |
cache-dependency-path: '**/pyproject.toml' | |
python-version: '3.10' | |
- name: Install Hatch | |
run: pip install hatch | |
- name: Run unit tests | |
run: make dev test | |
- name: Publish test coverage to coverage site | |
uses: codecov/codecov-action@v4 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
name: dbldatagen | |
files: ./coverage.xml | |