aqualisys 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- aqualisys-0.1.0/.github/workflows/ci.yml +46 -0
- aqualisys-0.1.0/.github/workflows/release.yml +161 -0
- aqualisys-0.1.0/.gitignore +207 -0
- aqualisys-0.1.0/LICENSE +21 -0
- aqualisys-0.1.0/PKG-INFO +59 -0
- aqualisys-0.1.0/README.md +40 -0
- aqualisys-0.1.0/configs/orders.yml +15 -0
- aqualisys-0.1.0/docs/PUBLISHING.md +49 -0
- aqualisys-0.1.0/docs/ROADMAP.md +36 -0
- aqualisys-0.1.0/pyproject.toml +44 -0
- aqualisys-0.1.0/src/aqualisys/__init__.py +19 -0
- aqualisys-0.1.0/src/aqualisys/checker.py +98 -0
- aqualisys-0.1.0/src/aqualisys/checks/__init__.py +3 -0
- aqualisys-0.1.0/src/aqualisys/checks/base.py +55 -0
- aqualisys-0.1.0/src/aqualisys/checks/rules.py +130 -0
- aqualisys-0.1.0/src/aqualisys/cli.py +44 -0
- aqualisys-0.1.0/src/aqualisys/config.py +112 -0
- aqualisys-0.1.0/src/aqualisys/logging/__init__.py +3 -0
- aqualisys-0.1.0/src/aqualisys/logging/base.py +37 -0
- aqualisys-0.1.0/src/aqualisys/logging/sqlite.py +113 -0
- aqualisys-0.1.0/tests/conftest.py +7 -0
- aqualisys-0.1.0/tests/unit/test_checker.py +41 -0
- aqualisys-0.1.0/tests/unit/test_rules.py +49 -0
- aqualisys-0.1.0/uv.lock +586 -0
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: ["main"]
|
|
6
|
+
tags: ["v*"]
|
|
7
|
+
pull_request:
|
|
8
|
+
branches: ["main"]
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
lint:
|
|
12
|
+
runs-on: ubuntu-latest
|
|
13
|
+
strategy:
|
|
14
|
+
matrix:
|
|
15
|
+
python-version: ["3.11", "3.12", "3.13", "3.14"]
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v4
|
|
18
|
+
- uses: actions/setup-python@v5
|
|
19
|
+
with:
|
|
20
|
+
python-version: ${{ matrix.python-version }}
|
|
21
|
+
- name: Install dependencies
|
|
22
|
+
run: |
|
|
23
|
+
python -m pip install --upgrade pip
|
|
24
|
+
pip install -e '.[dev]'
|
|
25
|
+
- name: Ruff
|
|
26
|
+
run: ruff check src tests
|
|
27
|
+
- name: Black
|
|
28
|
+
run: black --check src tests
|
|
29
|
+
|
|
30
|
+
tests:
|
|
31
|
+
needs: lint
|
|
32
|
+
runs-on: ubuntu-latest
|
|
33
|
+
strategy:
|
|
34
|
+
matrix:
|
|
35
|
+
python-version: ["3.11", "3.12", "3.13", "3.14"]
|
|
36
|
+
steps:
|
|
37
|
+
- uses: actions/checkout@v4
|
|
38
|
+
- uses: actions/setup-python@v5
|
|
39
|
+
with:
|
|
40
|
+
python-version: ${{ matrix.python-version }}
|
|
41
|
+
- name: Install dependencies
|
|
42
|
+
run: |
|
|
43
|
+
python -m pip install --upgrade pip
|
|
44
|
+
pip install -e '.[dev]'
|
|
45
|
+
- name: Pytest
|
|
46
|
+
run: pytest -vv
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- "v*"
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
wait-for-ci:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
steps:
|
|
12
|
+
- name: Wait for CI workflow
|
|
13
|
+
uses: actions/github-script@v7
|
|
14
|
+
with:
|
|
15
|
+
script: |
|
|
16
|
+
const workflowName = "CI";
|
|
17
|
+
const sha = process.env.GITHUB_SHA;
|
|
18
|
+
const owner = context.repo.owner;
|
|
19
|
+
const repo = context.repo.repo;
|
|
20
|
+
|
|
21
|
+
const delay = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
|
|
22
|
+
|
|
23
|
+
for (let attempt = 0; attempt < 30; attempt++) {
|
|
24
|
+
const { data } = await github.rest.actions.listWorkflowRunsForRepo({
|
|
25
|
+
owner,
|
|
26
|
+
repo,
|
|
27
|
+
event: "push",
|
|
28
|
+
head_sha: sha,
|
|
29
|
+
per_page: 50,
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
const run = data.workflow_runs.find((r) => r.name === workflowName);
|
|
33
|
+
if (run) {
|
|
34
|
+
if (run.status === "completed") {
|
|
35
|
+
if (run.conclusion !== "success") {
|
|
36
|
+
core.setFailed(`CI workflow finished with status ${run.conclusion}`);
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
core.info(`CI workflow ${run.id} succeeded.`);
|
|
40
|
+
return;
|
|
41
|
+
}
|
|
42
|
+
core.info(`CI workflow ${run.id} still running (attempt ${attempt + 1}).`);
|
|
43
|
+
} else {
|
|
44
|
+
core.info(`No CI workflow run found yet (attempt ${attempt + 1}).`);
|
|
45
|
+
}
|
|
46
|
+
await delay(30000);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
core.setFailed("Timed out waiting for CI workflow to complete.");
|
|
50
|
+
|
|
51
|
+
build:
|
|
52
|
+
needs: wait-for-ci
|
|
53
|
+
runs-on: ubuntu-latest
|
|
54
|
+
outputs:
|
|
55
|
+
release_tag: ${{ steps.tag_check.outputs.release_tag }}
|
|
56
|
+
steps:
|
|
57
|
+
- uses: actions/checkout@v4
|
|
58
|
+
with:
|
|
59
|
+
ref: ${{ github.sha }}
|
|
60
|
+
fetch-depth: 0
|
|
61
|
+
|
|
62
|
+
- name: Ensure tag release
|
|
63
|
+
id: tag_check
|
|
64
|
+
run: |
|
|
65
|
+
TAG_NAME="$(git describe --tags --exact-match HEAD 2>/dev/null || true)"
|
|
66
|
+
if [ -z "$TAG_NAME" ]; then
|
|
67
|
+
echo "This commit is not tagged; skipping release build."
|
|
68
|
+
echo "release_tag=" >> "$GITHUB_OUTPUT"
|
|
69
|
+
exit 0
|
|
70
|
+
fi
|
|
71
|
+
if [[ "$TAG_NAME" != v* ]]; then
|
|
72
|
+
echo "Tag $TAG_NAME does not match v* pattern; skipping."
|
|
73
|
+
echo "release_tag=" >> "$GITHUB_OUTPUT"
|
|
74
|
+
exit 0
|
|
75
|
+
fi
|
|
76
|
+
echo "release_tag=$TAG_NAME" >> "$GITHUB_OUTPUT"
|
|
77
|
+
|
|
78
|
+
- name: Set up Python
|
|
79
|
+
uses: actions/setup-python@v5
|
|
80
|
+
with:
|
|
81
|
+
python-version: "3.12"
|
|
82
|
+
|
|
83
|
+
- name: Install uv
|
|
84
|
+
uses: astral-sh/setup-uv@v2
|
|
85
|
+
|
|
86
|
+
- name: Build package
|
|
87
|
+
if: ${{ steps.tag_check.outputs.release_tag != '' }}
|
|
88
|
+
run: uv build
|
|
89
|
+
|
|
90
|
+
- name: Upload dist artifacts
|
|
91
|
+
if: ${{ steps.tag_check.outputs.release_tag != '' }}
|
|
92
|
+
uses: actions/upload-artifact@v4
|
|
93
|
+
with:
|
|
94
|
+
name: aqualisys-dist
|
|
95
|
+
path: dist/*
|
|
96
|
+
|
|
97
|
+
publish-testpypi:
|
|
98
|
+
needs: build
|
|
99
|
+
if: ${{ needs.build.result == 'success' && needs.build.outputs.release_tag != '' }}
|
|
100
|
+
runs-on: ubuntu-latest
|
|
101
|
+
outputs:
|
|
102
|
+
published: ${{ steps.publish.outputs.published }}
|
|
103
|
+
steps:
|
|
104
|
+
- uses: actions/checkout@v4
|
|
105
|
+
with:
|
|
106
|
+
ref: ${{ github.sha }}
|
|
107
|
+
fetch-depth: 0
|
|
108
|
+
- uses: actions/setup-python@v5
|
|
109
|
+
with:
|
|
110
|
+
python-version: "3.12"
|
|
111
|
+
- uses: astral-sh/setup-uv@v2
|
|
112
|
+
- name: Build dist for publishing
|
|
113
|
+
run: uv build
|
|
114
|
+
- id: publish
|
|
115
|
+
env:
|
|
116
|
+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
|
|
117
|
+
UV_PUBLISH_PASSWORD: ${{ secrets.TEST_PYPI_API_TOKEN }}
|
|
118
|
+
UV_PUBLISH_URL: https://test.pypi.org/legacy/
|
|
119
|
+
UV_PUBLISH_USERNAME: __token__
|
|
120
|
+
run: |
|
|
121
|
+
if [ -z "$TEST_PYPI_API_TOKEN" ]; then
|
|
122
|
+
echo "published=false" >> "$GITHUB_OUTPUT"
|
|
123
|
+
echo "TEST_PYPI_API_TOKEN not set; skipping TestPyPI publish."
|
|
124
|
+
exit 0
|
|
125
|
+
fi
|
|
126
|
+
uv publish
|
|
127
|
+
echo "published=true" >> "$GITHUB_OUTPUT"
|
|
128
|
+
|
|
129
|
+
publish-pypi:
|
|
130
|
+
needs:
|
|
131
|
+
- build
|
|
132
|
+
- publish-testpypi
|
|
133
|
+
if: >-
|
|
134
|
+
${{
|
|
135
|
+
needs.build.result == 'success' &&
|
|
136
|
+
needs.build.outputs.release_tag != '' &&
|
|
137
|
+
needs.publish-testpypi.outputs.published == 'true'
|
|
138
|
+
}}
|
|
139
|
+
runs-on: ubuntu-latest
|
|
140
|
+
steps:
|
|
141
|
+
- uses: actions/checkout@v4
|
|
142
|
+
with:
|
|
143
|
+
ref: ${{ github.sha }}
|
|
144
|
+
fetch-depth: 0
|
|
145
|
+
- uses: actions/setup-python@v5
|
|
146
|
+
with:
|
|
147
|
+
python-version: "3.12"
|
|
148
|
+
- uses: astral-sh/setup-uv@v2
|
|
149
|
+
- name: Build dist for publishing
|
|
150
|
+
run: uv build
|
|
151
|
+
- name: Publish to PyPI
|
|
152
|
+
env:
|
|
153
|
+
PYPI_API_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
|
|
154
|
+
UV_PUBLISH_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
|
|
155
|
+
UV_PUBLISH_USERNAME: __token__
|
|
156
|
+
run: |
|
|
157
|
+
if [ -z "$PYPI_API_TOKEN" ]; then
|
|
158
|
+
echo "PYPI_API_TOKEN not set; aborting PyPI publish."
|
|
159
|
+
exit 1
|
|
160
|
+
fi
|
|
161
|
+
uv publish
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[codz]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
share/python-wheels/
|
|
24
|
+
*.egg-info/
|
|
25
|
+
.installed.cfg
|
|
26
|
+
*.egg
|
|
27
|
+
MANIFEST
|
|
28
|
+
|
|
29
|
+
# PyInstaller
|
|
30
|
+
# Usually these files are written by a python script from a template
|
|
31
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
32
|
+
*.manifest
|
|
33
|
+
*.spec
|
|
34
|
+
|
|
35
|
+
# Installer logs
|
|
36
|
+
pip-log.txt
|
|
37
|
+
pip-delete-this-directory.txt
|
|
38
|
+
|
|
39
|
+
# Unit test / coverage reports
|
|
40
|
+
htmlcov/
|
|
41
|
+
.tox/
|
|
42
|
+
.nox/
|
|
43
|
+
.coverage
|
|
44
|
+
.coverage.*
|
|
45
|
+
.cache
|
|
46
|
+
nosetests.xml
|
|
47
|
+
coverage.xml
|
|
48
|
+
*.cover
|
|
49
|
+
*.py.cover
|
|
50
|
+
.hypothesis/
|
|
51
|
+
.pytest_cache/
|
|
52
|
+
cover/
|
|
53
|
+
|
|
54
|
+
# Translations
|
|
55
|
+
*.mo
|
|
56
|
+
*.pot
|
|
57
|
+
|
|
58
|
+
# Django stuff:
|
|
59
|
+
*.log
|
|
60
|
+
local_settings.py
|
|
61
|
+
db.sqlite3
|
|
62
|
+
db.sqlite3-journal
|
|
63
|
+
|
|
64
|
+
# Flask stuff:
|
|
65
|
+
instance/
|
|
66
|
+
.webassets-cache
|
|
67
|
+
|
|
68
|
+
# Scrapy stuff:
|
|
69
|
+
.scrapy
|
|
70
|
+
|
|
71
|
+
# Sphinx documentation
|
|
72
|
+
docs/_build/
|
|
73
|
+
|
|
74
|
+
# PyBuilder
|
|
75
|
+
.pybuilder/
|
|
76
|
+
target/
|
|
77
|
+
|
|
78
|
+
# Jupyter Notebook
|
|
79
|
+
.ipynb_checkpoints
|
|
80
|
+
|
|
81
|
+
# IPython
|
|
82
|
+
profile_default/
|
|
83
|
+
ipython_config.py
|
|
84
|
+
|
|
85
|
+
# pyenv
|
|
86
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
+
# .python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
+
# install all needed dependencies.
|
|
95
|
+
#Pipfile.lock
|
|
96
|
+
|
|
97
|
+
# UV
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
#uv.lock
|
|
102
|
+
|
|
103
|
+
# poetry
|
|
104
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
105
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
106
|
+
# commonly ignored for libraries.
|
|
107
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
108
|
+
#poetry.lock
|
|
109
|
+
#poetry.toml
|
|
110
|
+
|
|
111
|
+
# pdm
|
|
112
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
113
|
+
# pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
|
|
114
|
+
# https://pdm-project.org/en/latest/usage/project/#working-with-version-control
|
|
115
|
+
#pdm.lock
|
|
116
|
+
#pdm.toml
|
|
117
|
+
.pdm-python
|
|
118
|
+
.pdm-build/
|
|
119
|
+
|
|
120
|
+
# pixi
|
|
121
|
+
# Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
|
|
122
|
+
#pixi.lock
|
|
123
|
+
# Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
|
|
124
|
+
# in the .venv directory. It is recommended not to include this directory in version control.
|
|
125
|
+
.pixi
|
|
126
|
+
|
|
127
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
128
|
+
__pypackages__/
|
|
129
|
+
|
|
130
|
+
# Celery stuff
|
|
131
|
+
celerybeat-schedule
|
|
132
|
+
celerybeat.pid
|
|
133
|
+
|
|
134
|
+
# SageMath parsed files
|
|
135
|
+
*.sage.py
|
|
136
|
+
|
|
137
|
+
# Environments
|
|
138
|
+
.env
|
|
139
|
+
.envrc
|
|
140
|
+
.venv
|
|
141
|
+
env/
|
|
142
|
+
venv/
|
|
143
|
+
ENV/
|
|
144
|
+
env.bak/
|
|
145
|
+
venv.bak/
|
|
146
|
+
|
|
147
|
+
# Spyder project settings
|
|
148
|
+
.spyderproject
|
|
149
|
+
.spyproject
|
|
150
|
+
|
|
151
|
+
# Rope project settings
|
|
152
|
+
.ropeproject
|
|
153
|
+
|
|
154
|
+
# mkdocs documentation
|
|
155
|
+
/site
|
|
156
|
+
|
|
157
|
+
# mypy
|
|
158
|
+
.mypy_cache/
|
|
159
|
+
.dmypy.json
|
|
160
|
+
dmypy.json
|
|
161
|
+
|
|
162
|
+
# Pyre type checker
|
|
163
|
+
.pyre/
|
|
164
|
+
|
|
165
|
+
# pytype static type analyzer
|
|
166
|
+
.pytype/
|
|
167
|
+
|
|
168
|
+
# Cython debug symbols
|
|
169
|
+
cython_debug/
|
|
170
|
+
|
|
171
|
+
# PyCharm
|
|
172
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
173
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
174
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
175
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
176
|
+
.idea/
|
|
177
|
+
|
|
178
|
+
# Abstra
|
|
179
|
+
# Abstra is an AI-powered process automation framework.
|
|
180
|
+
# Ignore directories containing user credentials, local state, and settings.
|
|
181
|
+
# Learn more at https://abstra.io/docs
|
|
182
|
+
.abstra/
|
|
183
|
+
|
|
184
|
+
# Visual Studio Code
|
|
185
|
+
# Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
|
|
186
|
+
# that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
|
|
187
|
+
# and can be added to the global gitignore or merged into this file. However, if you prefer,
|
|
188
|
+
# you could uncomment the following to ignore the entire vscode folder
|
|
189
|
+
# .vscode/
|
|
190
|
+
|
|
191
|
+
# Ruff stuff:
|
|
192
|
+
.ruff_cache/
|
|
193
|
+
|
|
194
|
+
# PyPI configuration file
|
|
195
|
+
.pypirc
|
|
196
|
+
|
|
197
|
+
# Cursor
|
|
198
|
+
# Cursor is an AI-powered code editor. `.cursorignore` specifies files/directories to
|
|
199
|
+
# exclude from AI features like autocomplete and code analysis. Recommended for sensitive data
|
|
200
|
+
# refer to https://docs.cursor.com/context/ignore-files
|
|
201
|
+
.cursorignore
|
|
202
|
+
.cursorindexingignore
|
|
203
|
+
|
|
204
|
+
# Marimo
|
|
205
|
+
marimo/_static/
|
|
206
|
+
marimo/_lsp/
|
|
207
|
+
__marimo__/
|
aqualisys-0.1.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Absolentia
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
aqualisys-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: aqualisys
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Polars-first data-quality and data-validation toolkit.
|
|
5
|
+
Author-email: Aqualisys Maintainers <maintainers@aqualisys.dev>
|
|
6
|
+
License: MIT
|
|
7
|
+
License-File: LICENSE
|
|
8
|
+
Requires-Python: >=3.11
|
|
9
|
+
Requires-Dist: click>=8.1.7
|
|
10
|
+
Requires-Dist: polars>=0.20.0
|
|
11
|
+
Requires-Dist: pyyaml>=6.0.1
|
|
12
|
+
Provides-Extra: dev
|
|
13
|
+
Requires-Dist: black>=24.3.0; extra == 'dev'
|
|
14
|
+
Requires-Dist: mypy>=1.8.0; extra == 'dev'
|
|
15
|
+
Requires-Dist: pytest-cov>=4.1.0; extra == 'dev'
|
|
16
|
+
Requires-Dist: pytest>=7.4.4; extra == 'dev'
|
|
17
|
+
Requires-Dist: ruff>=0.2.1; extra == 'dev'
|
|
18
|
+
Description-Content-Type: text/markdown
|
|
19
|
+
|
|
20
|
+
# Aqualisys
|
|
21
|
+
|
|
22
|
+
Polars-first data-quality toolkit delivering deterministic validation, structured logging, and a composable rule registry.
|
|
23
|
+
|
|
24
|
+
## Why Aqualisys?
|
|
25
|
+
- **Declarative rules**: ship reusable expectations such as not-null, uniqueness, accepted-values, and referential checks.
|
|
26
|
+
- **Deterministic logging**: every run is persisted to SQLite (JSON-friendly) for audits and debugging.
|
|
27
|
+
- **Pipeline-ready**: run from Python code or via `aqualisys validate configs/orders.yml` in CI.
|
|
28
|
+
|
|
29
|
+
## Quick Start
|
|
30
|
+
```bash
|
|
31
|
+
python -m venv .venv && source .venv/bin/activate
|
|
32
|
+
pip install -e .[dev]
|
|
33
|
+
pytest
|
|
34
|
+
aqualisys validate configs/orders.yml
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## Usage Example
|
|
38
|
+
```python
|
|
39
|
+
import polars as pl
|
|
40
|
+
from aqualisys import DataQualityChecker, NotNullRule, UniqueRule, SQLiteRunLogger
|
|
41
|
+
|
|
42
|
+
df = pl.DataFrame({"order_id": [1, 2, 3], "status": ["pending", "shipped", "shipped"]})
|
|
43
|
+
checker = DataQualityChecker(
|
|
44
|
+
rules=[NotNullRule("order_id"), UniqueRule("order_id")],
|
|
45
|
+
logger=SQLiteRunLogger("artifacts/example_runs.db"),
|
|
46
|
+
)
|
|
47
|
+
report = checker.run(df, dataset_name="orders")
|
|
48
|
+
assert report.passed
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## Project Structure
|
|
52
|
+
- `src/aqualisys/`: library source (rules, checker, logging, CLI).
|
|
53
|
+
- `tests/`: pytest suites (unit + integration).
|
|
54
|
+
- `configs/`: sample validation suite definitions.
|
|
55
|
+
- `docs/`: roadmap and design notes.
|
|
56
|
+
|
|
57
|
+
See `docs/PUBLISHING.md` for uv-based build and release steps once you are ready to publish a new version.
|
|
58
|
+
|
|
59
|
+
See `docs/ROADMAP.md` for the multi-week implementation plan inspired by the Start Data Engineering guide.
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Aqualisys
|
|
2
|
+
|
|
3
|
+
Polars-first data-quality toolkit delivering deterministic validation, structured logging, and a composable rule registry.
|
|
4
|
+
|
|
5
|
+
## Why Aqualisys?
|
|
6
|
+
- **Declarative rules**: ship reusable expectations such as not-null, uniqueness, accepted-values, and referential checks.
|
|
7
|
+
- **Deterministic logging**: every run is persisted to SQLite (JSON-friendly) for audits and debugging.
|
|
8
|
+
- **Pipeline-ready**: run from Python code or via `aqualisys validate configs/orders.yml` in CI.
|
|
9
|
+
|
|
10
|
+
## Quick Start
|
|
11
|
+
```bash
|
|
12
|
+
python -m venv .venv && source .venv/bin/activate
|
|
13
|
+
pip install -e .[dev]
|
|
14
|
+
pytest
|
|
15
|
+
aqualisys validate configs/orders.yml
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## Usage Example
|
|
19
|
+
```python
|
|
20
|
+
import polars as pl
|
|
21
|
+
from aqualisys import DataQualityChecker, NotNullRule, UniqueRule, SQLiteRunLogger
|
|
22
|
+
|
|
23
|
+
df = pl.DataFrame({"order_id": [1, 2, 3], "status": ["pending", "shipped", "shipped"]})
|
|
24
|
+
checker = DataQualityChecker(
|
|
25
|
+
rules=[NotNullRule("order_id"), UniqueRule("order_id")],
|
|
26
|
+
logger=SQLiteRunLogger("artifacts/example_runs.db"),
|
|
27
|
+
)
|
|
28
|
+
report = checker.run(df, dataset_name="orders")
|
|
29
|
+
assert report.passed
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Project Structure
|
|
33
|
+
- `src/aqualisys/`: library source (rules, checker, logging, CLI).
|
|
34
|
+
- `tests/`: pytest suites (unit + integration).
|
|
35
|
+
- `configs/`: sample validation suite definitions.
|
|
36
|
+
- `docs/`: roadmap and design notes.
|
|
37
|
+
|
|
38
|
+
See `docs/PUBLISHING.md` for uv-based build and release steps once you are ready to publish a new version.
|
|
39
|
+
|
|
40
|
+
See `docs/ROADMAP.md` for the multi-week implementation plan inspired by the Start Data Engineering guide.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
dataset:
|
|
2
|
+
name: orders
|
|
3
|
+
path: data/orders.parquet
|
|
4
|
+
format: parquet
|
|
5
|
+
fail_fast: true
|
|
6
|
+
logger:
|
|
7
|
+
path: artifacts/orders_runs.db
|
|
8
|
+
rules:
|
|
9
|
+
- type: not_null
|
|
10
|
+
column: order_id
|
|
11
|
+
- type: unique
|
|
12
|
+
column: order_id
|
|
13
|
+
- type: accepted_values
|
|
14
|
+
column: order_status
|
|
15
|
+
allowed_values: ["pending", "shipped", "delivered", "cancelled"]
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Publishing & Release Guide
|
|
2
|
+
|
|
3
|
+
This guide mirrors the Week 4 "DX & Publishing" milestone from the roadmap. It assumes you have uv installed locally (https://docs.astral.sh/uv/).
|
|
4
|
+
|
|
5
|
+
## 1. Build the distribution artifacts
|
|
6
|
+
```bash
|
|
7
|
+
uv build
|
|
8
|
+
```
|
|
9
|
+
Outputs land in `dist/` as both an sdist (`.tar.gz`) and wheel (`.whl`). Inspect them locally if needed:
|
|
10
|
+
```bash
|
|
11
|
+
ls dist
|
|
12
|
+
uv pip install dist/aqualisys-*.whl --target /tmp/aqualisys-wheel-check
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## 2. Smoke-test from a clean environment
|
|
16
|
+
```bash
|
|
17
|
+
python -m venv /tmp/aqualisys-smoke
|
|
18
|
+
source /tmp/aqualisys-smoke/bin/activate
|
|
19
|
+
pip install --upgrade pip
|
|
20
|
+
pip install dist/aqualisys-*.whl
|
|
21
|
+
python - <<'PY'
|
|
22
|
+
from aqualisys import DataQualityChecker, NotNullRule
|
|
23
|
+
print("Loaded", DataQualityChecker, NotNullRule)
|
|
24
|
+
PY
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## 3. Publish to TestPyPI first
|
|
28
|
+
```bash
|
|
29
|
+
uv publish --repository testpypi --token "$TEST_PYPI_API_TOKEN"
|
|
30
|
+
```
|
|
31
|
+
Retrieve the token from https://test.pypi.org/manage/account/token/ and store it in the `TEST_PYPI_API_TOKEN` environment variable (or GitHub secret of the same name). After publishing, install from TestPyPI to verify:
|
|
32
|
+
```bash
|
|
33
|
+
pip install --index-url https://test.pypi.org/simple --no-deps aqualisys
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
## 4. Promote to PyPI
|
|
37
|
+
Once TestPyPI validation passes:
|
|
38
|
+
```bash
|
|
39
|
+
uv publish --token "$PYPI_API_TOKEN"
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## 5. GitHub Actions workflow
|
|
43
|
+
Pushing a tag like `v0.2.0` triggers `.github/workflows/release.yml`, which:
|
|
44
|
+
1. Checks out the repo.
|
|
45
|
+
2. Sets up Python 3.12 and uv.
|
|
46
|
+
3. Runs `uv build`.
|
|
47
|
+
4. Uploads `dist/` as a workflow artifact.
|
|
48
|
+
|
|
49
|
+
If `TEST_PYPI_API_TOKEN` or `PYPI_API_TOKEN` secrets exist, the workflow also attempts to publish. Keep those secrets scoped to org/repo maintainers.
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# Aqualisys Roadmap
|
|
2
|
+
|
|
3
|
+
## Vision & Scope
|
|
4
|
+
- **Audience**: Data engineers who need deterministic, scriptable data-quality checks on Polars DataFrames up to ~100 GB in-memory workloads.
|
|
5
|
+
- **Problem**: Automate repetitive assertions (uniqueness, non-null, accepted-value, relationship checks) while logging all outcomes for auditability.
|
|
6
|
+
- **Constraints**: Operate on Polars inputs only in v0.x, log validation metadata (dataset, run_id, rule_id, metric/value) to SQLite for easy inspection, keep validator and logger orthogonal so either can be swapped later.
|
|
7
|
+
|
|
8
|
+
## System Architecture Snapshot
|
|
9
|
+
- **Validator Layer**: `DataQualityChecker` orchestrates rule execution. Rules are composable callables implementing a `BaseRule` protocol. Supports registry + bundles for domain suites.
|
|
10
|
+
- **Logging Layer**: `SQLiteRunLogger` implements an abstract `RunLogger` interface capturing run context + rule results. Future connectors (DuckDB, HTTP) can reuse the interface.
|
|
11
|
+
- **Configuration Layer**: Simple `ValidationConfig` dataclass (YAML/JSON loading later) ties inputs, selected rule bundles, and thresholds. Flags (fail fast, severity) stored here.
|
|
12
|
+
- **CLI/Script Layer**: `aqualisys validate --config configs/orders.yml` entry point enabling pipeline integration. CLI delegates entirely to the library.
|
|
13
|
+
|
|
14
|
+
## Milestones
|
|
15
|
+
1. **Foundation (Week 1)**
|
|
16
|
+
- Scaffold repo: `pyproject.toml`, `src/aqualisys`, `tests`.
|
|
17
|
+
- Implement minimal Polars rule set (unique, not_null) and SQLite logger.
|
|
18
|
+
- Provide quick-start documentation + architecture diagrams in README.
|
|
19
|
+
2. **Rule Expansion (Week 2)**
|
|
20
|
+
- Add accepted-values, referential-integrity, expression-based checks.
|
|
21
|
+
- Introduce rule registry + tagging for bundles.
|
|
22
|
+
- Emit structured results (JSON + SQLite) to support downstream observability.
|
|
23
|
+
3. **Configuration & CLI (Week 3)**
|
|
24
|
+
- YAML config parser, CLI wrappers for running suites locally or in CI.
|
|
25
|
+
- Support `--fail-fast`, severity overrides, include/exclude selectors.
|
|
26
|
+
- Harden logging with retries + summary tables.
|
|
27
|
+
4. **DX & Publishing (Week 4)**
|
|
28
|
+
- Add docs site snippets, end-to-end demo notebook, telemetry opt-in.
|
|
29
|
+
- Set up `uv build`, publish to TestPyPI, smoke-test install, then promote to PyPI.
|
|
30
|
+
- Configure CI (lint, type-check, pytest with coverage) and badges.
|
|
31
|
+
|
|
32
|
+
## Success Metrics
|
|
33
|
+
- Unit + integration coverage ≥90% on validators/loggers.
|
|
34
|
+
- Ability to run ≥50 rules/minute on 1M-row datasets on a laptop.
|
|
35
|
+
- Users can onboard by running a single CLI command using sample configs.
|
|
36
|
+
- Release cadence: tagged versions every 2 weeks during v0 development.
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "aqualisys"
|
|
7
|
+
version = "0.1.0"
|
|
8
|
+
description = "Polars-first data-quality and data-validation toolkit."
|
|
9
|
+
authors = [{ name = "Aqualisys Maintainers", email = "maintainers@aqualisys.dev" }]
|
|
10
|
+
readme = "README.md"
|
|
11
|
+
requires-python = ">=3.11"
|
|
12
|
+
license = { text = "MIT" }
|
|
13
|
+
dependencies = [
|
|
14
|
+
"click>=8.1.7",
|
|
15
|
+
"polars>=0.20.0",
|
|
16
|
+
"pyyaml>=6.0.1",
|
|
17
|
+
]
|
|
18
|
+
|
|
19
|
+
[project.optional-dependencies]
|
|
20
|
+
dev = [
|
|
21
|
+
"black>=24.3.0",
|
|
22
|
+
"mypy>=1.8.0",
|
|
23
|
+
"pytest>=7.4.4",
|
|
24
|
+
"pytest-cov>=4.1.0",
|
|
25
|
+
"ruff>=0.2.1",
|
|
26
|
+
]
|
|
27
|
+
|
|
28
|
+
[project.scripts]
|
|
29
|
+
aqualisys = "aqualisys.cli:run"
|
|
30
|
+
|
|
31
|
+
[tool.black]
|
|
32
|
+
line-length = 88
|
|
33
|
+
target-version = ["py311"]
|
|
34
|
+
|
|
35
|
+
[tool.ruff]
|
|
36
|
+
target-version = "py311"
|
|
37
|
+
line-length = 88
|
|
38
|
+
|
|
39
|
+
[tool.ruff.lint]
|
|
40
|
+
select = ["E", "F", "I", "UP", "B"]
|
|
41
|
+
|
|
42
|
+
[tool.pytest.ini_options]
|
|
43
|
+
addopts = "-vv --strict-markers"
|
|
44
|
+
testpaths = ["tests"]
|