From c02a0287fc9a3acbf936df0fd14acb96b628bea4 Mon Sep 17 00:00:00 2001 From: Stefaan Lippens Date: Wed, 12 Feb 2025 11:25:16 +0100 Subject: [PATCH] Issue #173 fix compatibility with openeo-driver 0.126 --- CHANGELOG.md | 2 ++ setup.py | 2 +- tests/partitionedjobs/test_api.py | 2 ++ tests/test_views.py | 2 ++ 4 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d74e6b2..3fb4a37 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,8 @@ The format is roughly based on [Keep a Changelog](https://keepachangelog.com/en/ - Add "openEO Federation Extension" to conformance classes ([#169](https://github.com/Open-EO/openeo-aggregator/issues/169)) - Update to openeo python client version 0.38.0 ([#170](https://github.com/Open-EO/openeo-aggregator/issues/170)) +- Fix compatibility with openeo-driver 0.126 ([#173](https://github.com/Open-EO/openeo-aggregator/issues/173)) + ## 0.41.0 diff --git a/setup.py b/setup.py index 89d3b3b..47e7767 100644 --- a/setup.py +++ b/setup.py @@ -35,7 +35,7 @@ "requests", "attrs", "openeo>=0.38.0", - "openeo_driver>=0.123.0.dev,<0.125.0", + "openeo_driver>=0.126.1.dev", "flask~=2.0", "gunicorn~=20.0", "python-json-logger>=2.0.0", diff --git a/tests/partitionedjobs/test_api.py b/tests/partitionedjobs/test_api.py index 956cae6..237f007 100644 --- a/tests/partitionedjobs/test_api.py +++ b/tests/partitionedjobs/test_api.py @@ -239,6 +239,7 @@ def test_create_job_failed_backend(self, api100, zk_db, requests_mock, dummy1): res = api100.get(f"/jobs/{expected_job_id}/logs").assert_status_code(200) assert res.json == { + "level": "debug", "logs": [{"id": "0000-0", "level": "error", "message": approx_str_contains("NoJobIdForSubJob")}], "links": [], } @@ -449,6 +450,7 @@ def test_get_logs(self, api100, requests_mock, dummy1): res = api100.get(f"/jobs/{expected_job_id}/logs").assert_status_code(200) assert res.json == { + "level": "debug", "logs": [{"id": "0000-123", "level": "info", "message": "Created job. You're welcome."}], "links": [], } diff --git a/tests/test_views.py b/tests/test_views.py index 4f237f6..0952f23 100644 --- a/tests/test_views.py +++ b/tests/test_views.py @@ -2334,6 +2334,7 @@ def get_logs(request, context): api100.set_auth_bearer_token(token=TEST_USER_BEARER_TOKEN) res = api100.get("/jobs/b1-th3j0b/logs").assert_status_code(200).json assert res == { + "level": "debug", "logs": [ {"id": "_1", "level": "info", "message": "hello"}, {"id": "_11", "level": "info", "message": "hello"}, @@ -2343,6 +2344,7 @@ def get_logs(request, context): res = api100.get("/jobs/b1-th3j0b/logs?offset=3").assert_status_code(200).json assert res == { + "level": "debug", "logs": [ {"id": "31", "level": "info", "message": "hello"}, {"id": "311", "level": "info", "message": "hello"},