From ce091dd129a26f6d77fe0627cb87a89a7db93c83 Mon Sep 17 00:00:00 2001 From: Martin Kinkelin Date: Wed, 24 Jul 2024 14:40:19 +0200 Subject: [PATCH 1/2] Switch from vibe-d:data to vibe-serialization dependency AFAICT, this was extracted from vibe-d:data in February. It only depends on vibe-container, which only depends on stdx-allocator, which only depends on mir-core. So this should significantly reduce the overall dpq2 dub dependencies. --- dub.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dub.json b/dub.json index afb43ccc..ce2b9343 100644 --- a/dub.json +++ b/dub.json @@ -9,7 +9,7 @@ "targetPath": "bin", "dependencies": { "derelict-pq": "~>4.0.0", - "vibe-d:data": ">=0.8.3-beta.1 <0.11.0", + "vibe-serialization": "~>1.0.4", "money": "~>3.0.2" }, "targetType": "sourceLibrary", @@ -47,7 +47,7 @@ "dependencies": { "dpq2": { "version": "*", "dflags-dmd": ["-preview=in"] }, - "vibe-d:data": { "version": "*", "dflags-dmd": ["-preview=in"] }, + "vibe-serialization": { "version": "*", "dflags-dmd": ["-preview=in"] }, "gfm:math": "~>8.0.6" }, "configurations": [ @@ -82,7 +82,7 @@ "dependencies": { "dpq2": { "version": "*", "dflags": ["-preview=in"] }, - "vibe-d:data": { "version": "*", "dflags": ["-preview=in"] }, + "vibe-serialization": { "version": "*", "dflags": ["-preview=in"] }, }, "sourcePaths": [ "example" ] } From 8f73ecac48e63b04db36f7b29a5730675b2b48a5 Mon Sep 17 00:00:00 2001 From: Denis Feklushkin Date: Wed, 24 Jul 2024 19:50:42 +0300 Subject: [PATCH 2/2] Sporadic integration test failure fix --- src/dpq2/query.d | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/dpq2/query.d b/src/dpq2/query.d index 4dd17cc6..5c493762 100644 --- a/src/dpq2/query.d +++ b/src/dpq2/query.d @@ -501,6 +501,8 @@ void _integration_test( string connParam ) @trusted conn.socket.shutdown(SocketShutdown.BOTH); // breaks connection { + import dpq2.result: ResponseException; + bool exceptionFlag = false; string errorMsg; @@ -511,6 +513,12 @@ void _integration_test( string connParam ) @trusted errorMsg = e.msg; assert(e.msg.length > 15); // error message check } + catch(ResponseException e) + { + exceptionFlag = true; + errorMsg = e.msg; + assert(e.msg.length > 15); // error message check + } finally { assert(exceptionFlag, errorMsg); }