From 1102e2aff0a9cf80408e2ccf6db2bfd5a0d3e150 Mon Sep 17 00:00:00 2001 From: Alexey Masterov Date: Fri, 18 Jul 2025 14:42:28 +0200 Subject: [PATCH] Add connect_env --- test_runner/random_ops/test_random_ops.py | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/test_runner/random_ops/test_random_ops.py b/test_runner/random_ops/test_random_ops.py index 0fffa482a5..6a2661e1ec 100644 --- a/test_runner/random_ops/test_random_ops.py +++ b/test_runner/random_ops/test_random_ops.py @@ -533,8 +533,14 @@ class NeonProject: if ep.type == "read_write": new_branch.connection_parameters["host"] = ep.host break - # XXX do not merge - log.info("%s", new_branch.connection_parameters) + with new_branch.connection_parameters as cp: + new_branch.connect_env = { + "PGHOST": cp["host"], + "PGUSER": cp["role"], + "PGDATABASE": cp["database"], + "PGPASSWORD": cp["password"], + "PGSSLMODE": "require", + } with psycopg2.connect( host=new_branch.connection_parameters["host"], port=5432, @@ -571,8 +577,8 @@ def setup_class( if neon_api.retries4xx > 0: print(f"::warning::Retried on 4xx error {neon_api.retries4xx} times") # XXX Do not merge !!! - #log.info("Removing the project %s", project.id) - #project.delete() + # log.info("Removing the project %s", project.id) + # project.delete() def do_action(project: NeonProject, action: str) -> bool: