-
Notifications
You must be signed in to change notification settings - Fork 0
FEAT: PAAL-151 Add Testworkflows #3
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
Merged
Merged
Changes from all commits
Commits
Show all changes
62 commits
Select commit
Hold shift + click to select a range
c236889
FEAT: PAAL-151 Add Testworkflows
203f302
FEAT: Add unit tests & test datasets
f2d828d
FIX: Plenty of fixes / small refactorings in coordination with @fmall…
e34f2c8
FIX: reposition the call to evaluate() from calculate_metrics to main…
7beb1a7
FEAT: Migrate metrics publishing from Prometheus Pushgateway to OpenT…
fmallmann 6313bd6
FIX: TokenUsageParser now functions correctly even when using Non-LLM…
fb816c6
FIX: remove unused veriable 'df'
2d03f42
FIX: remove unused variable 'results' in run.py
6fba40d
feat: initial tilt setup
fmallmann 714f848
FEAT: added Bandit, MyPy, Import-Linter, Poe, Ruff
4622e5b
FIX: Formatting
7f35216
FIX: Formatting
c30b80a
FIX: Add config for Import-Linter, Ruff & Bandit to pyproject.toml
2bd09d4
FIX: Type Errors in run.py
bf019df
FIX: Type Errors in setup.py
ad397d0
FIX: Remove unnecessary dependencies & add missing ones
d7dda81
FIX: Type Errors in evaluate.py
8f36726
FIX: Add scripts/ to mypy_path
b027cbc
FIX: Adapt test_e2e.py as a Pytest and add it to the Workflows
ca36c95
FIX: Adapt test_publish.py to the OpenTelemetry OTLP, adjust Error in…
8072aa5
FEAT: Use Python Version File to set Python Version
8262252
FIX: setup of test-testworkflows.yml
986b301
FIX: setup of test-testworkflows.yml
45f7ba7
Merge remote-tracking branch 'origin/FEAT-PAAL-151-add-testworkflows'…
2116607
FEAT: add Tiltfile to test-testworkflows.yml to properly test test_e2…
d7db29a
FEAT: add Tiltfile to test-testworkflows.yml to properly test test_e2…
14882b1
FIX: Type Error in evaluate.py
a157286
FIX: Tiltfile Error in test-testworkflows.yml
e563571
FIX: Add GOOGLE_API_KEY Github Secret
8ad3ea1
FIX: wait for Test-Data-Server to start up before running Pytests
73c1f7a
FEAT: Implement Test-Data-Server in Github Action (Tilt CI shuts it d…
932009a
FIX: no more double Test-Data-Server in CI
ef13ef6
FIX: add OPENAI_API_KEY Placeholder so test_e2e.py can run
0525e6e
FIX: add Timeout to Request
2bb11ac
FIX: up2date uv.lock
cfe390f
FIX: ignore various low-risk warnings
de336ad
FEAT: Add Check Workflow that runs 'uv poe check'
701f8fa
FIX: incorrect path to python-version-file
b36a5fc
FIX: incorrect working-directory in check-testworkflows.yml
e36d99f
Revert "FIX: incorrect working-directory in check-testworkflows.yml"
333e5b0
Revert "FIX: incorrect path to python-version-file"
95c7231
Revert "FEAT: Add Check Workflow that runs 'uv poe check'"
ff6c5ae
REFACTOR: Adapt check-testworkflows.yml to run all checks instead of …
68704fb
FIX: update pyproject.toml and uv.lock
878f021
REFACTOR: create e2e_tests/ directory
08bc1ee
REFACTOR: add test_e2e to POE tasks
2b71106
REFACTOR: adapt test-e2e.yml to run the testworkflow e2e test
f905d5d
REFACTOR: rename to check.yml and remove E2E-Test scaffolding
63304ed
REFACTOR: replace Go Tests with Testworkflow Tests
90f23d3
FIX: Formatting
10d200f
FIX: Rename E2E Test folder
790128b
REFACTOR: divide dependencies into dev and prod
254bd7b
FIX: wrong directory for test_e2e
76d4065
FIX: adapt uv commands to dev & prod dependencies
0bd2bb7
FIX: use native Pytest functionality instead of importing Unittest
fe34bd0
FIX: remove issues Linter & Bandit currently ignore
c5fbfd3
FIX: Formatting
f04ba0a
FIX: Imports
d28695e
FIX: Imports
057a092
FIX: Update uv.lock
6e27c6c
FEAT: Documentation for Testworkflows
d1ee69e
REFACTOR: restructure Dependencies & dependency groups
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| # | ||
| # GitHub Action: Check | ||
| # | ||
| # This workflow is triggered on pushes to main and renovate branches, as well as | ||
| # pull requests. It runs backend checks to ensure code quality. | ||
| # | ||
| name: Check | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| - 'renovate/**' | ||
| pull_request: | ||
|
|
||
| jobs: | ||
| test-testworkflows: | ||
| name: Runs on Ubuntu | ||
| runs-on: ubuntu-latest | ||
|
|
||
| defaults: | ||
| run: | ||
| working-directory: testworkflows | ||
|
|
||
| steps: | ||
| - name: Clone the code | ||
| uses: 'actions/checkout@v5' | ||
|
|
||
| - name: Install uv | ||
| uses: 'astral-sh/setup-uv@v6' | ||
| with: | ||
| version: "0.8.17" | ||
| enable-cache: true | ||
|
|
||
| - name: Setup Python | ||
| uses: 'actions/setup-python@v6' | ||
| with: | ||
| python-version-file: "testworkflows/.python-version" | ||
|
|
||
| - name: Install Dependencies | ||
| run: uv sync | ||
|
|
||
| - name: Run Checks | ||
| run: uv run poe check |
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -25,3 +25,5 @@ go.work | |
| *.swp | ||
| *.swo | ||
| *~ | ||
|
|
||
| .env | ||
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,38 @@ | ||
| # -*- mode: Python -*- | ||
|
|
||
| # Increase Kubernetes upsert timeout for CRD installations | ||
| update_settings(max_parallel_updates=10) | ||
|
|
||
| # Load .env file for environment variables | ||
| load('ext://dotenv', 'dotenv') | ||
| dotenv() | ||
|
|
||
| v1alpha1.extension_repo(name='agentic-layer', url='https://github.com/agentic-layer/tilt-extensions', ref='v0.3.1') | ||
|
|
||
| v1alpha1.extension(name='cert-manager', repo_name='agentic-layer', repo_path='cert-manager') | ||
| load('ext://cert-manager', 'cert_manager_install') | ||
| cert_manager_install() | ||
|
|
||
| v1alpha1.extension(name='agent-runtime', repo_name='agentic-layer', repo_path='agent-runtime') | ||
| load('ext://agent-runtime', 'agent_runtime_install') | ||
| agent_runtime_install(version='0.9.0') | ||
|
|
||
| v1alpha1.extension(name='ai-gateway-litellm', repo_name='agentic-layer', repo_path='ai-gateway-litellm') | ||
| load('ext://ai-gateway-litellm', 'ai_gateway_litellm_install') | ||
| ai_gateway_litellm_install(version='0.2.0') | ||
|
|
||
| # Webserver to serve test data (disabled in CI - manually started instead) | ||
| if not os.getenv('CI'): | ||
| local_resource( | ||
| 'test-data-server', | ||
| serve_cmd='python3 -m http.server 8000 --directory testworkflows/tests/test_data', | ||
| labels=['test-data'], | ||
| links=['http://localhost:8000/dataset.json'] | ||
| ) | ||
|
|
||
| # Apply Kubernetes manifests | ||
| k8s_yaml(kustomize('deploy/local')) | ||
|
|
||
| k8s_resource('ai-gateway-litellm', port_forwards=['11001:4000']) | ||
| k8s_resource('weather-agent', port_forwards='11010:8000', labels=['agents'], resource_deps=['agent-runtime']) | ||
| k8s_resource('lgtm', port_forwards=['11000:3000', '9090:9090', '4318:4318']) |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| apiVersion: kustomize.config.k8s.io/v1beta1 | ||
| kind: Kustomization | ||
| resources: | ||
| - weather-agent.yaml | ||
| - lgtm.yaml |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,86 @@ | ||
| # this is intended for demo / testing purposes only, not for production usage | ||
| apiVersion: v1 | ||
| kind: Namespace | ||
| metadata: | ||
| name: monitoring | ||
| --- | ||
| apiVersion: v1 | ||
| kind: Service | ||
| metadata: | ||
| name: lgtm | ||
| namespace: monitoring | ||
| spec: | ||
| selector: | ||
| app: lgtm | ||
| ports: | ||
| - name: grafana | ||
| protocol: TCP | ||
| port: 3000 | ||
| targetPort: 3000 | ||
| - name: otel-grpc | ||
| protocol: TCP | ||
| port: 4317 | ||
| targetPort: 4317 | ||
| - name: otel-http | ||
| protocol: TCP | ||
| port: 4318 | ||
| targetPort: 4318 | ||
| - name: prometheus | ||
| protocol: TCP | ||
| port: 9090 | ||
| targetPort: 9090 | ||
| --- | ||
| apiVersion: apps/v1 | ||
| kind: Deployment | ||
| metadata: | ||
| name: lgtm | ||
| namespace: monitoring | ||
| spec: | ||
| replicas: 1 | ||
| selector: | ||
| matchLabels: | ||
| app: lgtm | ||
| template: | ||
| metadata: | ||
| labels: | ||
| app: lgtm | ||
| spec: | ||
| containers: | ||
| - name: lgtm | ||
| image: grafana/otel-lgtm:latest | ||
| ports: | ||
| - containerPort: 3000 | ||
| - containerPort: 4317 | ||
| - containerPort: 4318 | ||
| - containerPort: 9090 | ||
| readinessProbe: | ||
| exec: | ||
| command: | ||
| - cat | ||
| - /tmp/ready | ||
| volumeMounts: | ||
| - name: tempo-data | ||
| mountPath: /data/tempo | ||
| - name: grafana-data | ||
| mountPath: /data/grafana | ||
| - name: loki-data | ||
| mountPath: /data/loki | ||
| - name: loki-storage | ||
| mountPath: /loki | ||
| - name: p8s-storage | ||
| mountPath: /data/prometheus | ||
| - name: pyroscope-storage | ||
| mountPath: /data/pyroscope | ||
| volumes: | ||
| - name: tempo-data | ||
| emptyDir: {} | ||
| - name: loki-data | ||
| emptyDir: {} | ||
| - name: grafana-data | ||
| emptyDir: {} | ||
| - name: loki-storage | ||
| emptyDir: {} | ||
| - name: p8s-storage | ||
| emptyDir: {} | ||
| - name: pyroscope-storage | ||
| emptyDir: {} |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| kind: Namespace | ||
| apiVersion: v1 | ||
| metadata: | ||
| name: sample-agents | ||
| --- | ||
| apiVersion: runtime.agentic-layer.ai/v1alpha1 | ||
| kind: Agent | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/name: agent-runtime-operator | ||
| app.kubernetes.io/managed-by: kustomize | ||
| name: weather-agent | ||
| namespace: sample-agents | ||
| spec: | ||
| framework: google-adk | ||
| image: ghcr.io/agentic-layer/weather-agent:0.6.0 | ||
| protocols: | ||
| - type: A2A | ||
| exposed: true | ||
| env: | ||
| - name: OTEL_SDK_DISABLED | ||
| value: "true" |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| 3.13 |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.