Skip to content

Commit

Permalink
Merge pull request #1 from Iglesys347/feat/github-actions
Browse files Browse the repository at this point in the history
Create pylint.yml action
  • Loading branch information
Iglesys347 authored Mar 23, 2024
2 parents 8db2f75 + b3f3193 commit b497077
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 15 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/pylint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Pylint

on: [push]

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements/dev-requirements.txt
- name: Analysing the code with pylint
run: |
export PYTHONPATH=$(pwd)
pylint --fail-under=8 $(git ls-files 'src/*.py') --disable=C0114,C0115,C0116
21 changes: 6 additions & 15 deletions src/router/species.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,13 @@
from os import path
"""
TODO: species spefic endpoints:
- get the list of species
- get the list of sub-species (for each species)
"""

from fastapi import APIRouter, Depends, status, HTTPException
from fastapi.responses import FileResponse
from sqlalchemy.orm import Session

from src.dependencies import get_db

from src.models.responses import ErrorMessage

from src.database.crud import get_image
from fastapi import APIRouter


router = APIRouter(
prefix="/species",
tags=["species"],
)


# TODO: species spefic endpoints:
# - get the list of species
# - get the list of sub-species (for each species)

0 comments on commit b497077

Please sign in to comment.