Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(docstring-readme): finish docstring and write readme #16

Merged
Merged
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
28 changes: 28 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: CI Build

on:
workflow_dispatch:
push:
branches:
- "feature/**/**"
- "fix/**/**"
- "release/v*.*.*"

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
uses: actions/[email protected]
with:
python-version: ${{ matrix.python-version }}
cache: "pip"
- name: Install package and dependencies
run: |
python3 -m pip install --upgrade pip setuptools wheel
pip3 install -e .
84 changes: 0 additions & 84 deletions .github/workflows/ci.yaml

This file was deleted.

38 changes: 38 additions & 0 deletions .github/workflows/code-quality.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: CI Code Quality

on:
workflow_dispatch:
push:
branches:
- "feature/**/**"
- "fix/**/**"
- "release/v*.*.*"
workflow_run:
workflows: ["Build"]
types:
- completed

jobs:
code-quality:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
uses: actions/[email protected]
with:
python-version: ${{ matrix.python-version }}
cache: "pip"
- name: Install linting dependencies
run: |
python3 -m pip install --upgrade pip setuptools wheel
pip3 install -e .[codequality,extra]
- name: Lint with Black
run: black --config=pyproject.toml .
- name: Lint with Isort
run: isort --settings-path=pyproject.toml .
- name: Lint with MyPy
run: mypy --config-file=pyproject.toml --pretty .
46 changes: 46 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: CI Automated Testing

on:
workflow_dispatch:
push:
branches:
- "feature/**/**"
- "fix/**/**"
- "release/v*.*.*"
workflow_run:
workflows: ["Code Quality"]
types:
- completed

jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
uses: actions/[email protected]
with:
python-version: ${{ matrix.python-version }}
cache: "pip"
- name: Install package and dependencies
run: |
python3 -m pip install --upgrade pip setuptools wheel
pip3 install -e .[security,testcov,extra]
- name: Test application's vulnerability with bandit
run: bandit -c pyproject.toml -r .
- name: Test with Pytest-Cov
run: |
pytest --cov --cov-report xml .
- name: Upload coverage to Codecov
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
flags: anomalytics
name: codecov-umbrella
verbose: true
29 changes: 29 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Changelog

<!--next-version-placeholder-->

## v0.1.0 (04/12/2023)

- First release of `anomalytics`

### Feature

- Added documentation directory and its main modules in `anomalytics/docs/*`
- Added a list of code owners in `github/CODEOWNERS`
- Added 3 jobs: build, code-quality, and test for CI in `github/workflows/*.yaml`
- Added "QQ Plot" test for visual evaluation in `anomalytics/evals/qq_plot.py`
- Added "Kolmogorov Smirnov" test for model evaluation in `anomalytics/evals/kolmogorov_smirnov.py`
- Added anomaly detection with Peaks Over Threshold method in `anomalytics/stats/peaks_over_threshold.py`
- Added abstraction layer for all time window calculation functions in `anomalytics/time_windows/time_window.py`
- Added function to calculate time windows for POT (t0, t1, t2) in `anomalytics/time_windows/pot_window.py`
- Added lazy upload functions and its abstraction layer to create Pandas Series in `anomalytics/time_series/upload.py`
- Added project setup via TOML in `./pyproject.toml`

### Tests

- Added unit tests for evals modules in `tests/test_evaluation_methods.py`
- Added unit tests for stats modules in `tests/test_peaks_over_threshold.py`
- Added unit tests for time_windows modules in `tests/test_time_windows.py`
- Added unit tests for time_series modules in `tests/test_time_series.py`
- Added unit tests for anomalytics version in `tests/test_version.py`
- Added main test config file for future use in `tests/conftest.py`
Loading