From 20c201393024eba6387f87c031bfea420bbc49e4 Mon Sep 17 00:00:00 2001 From: jeremyhi Date: Tue, 13 Oct 2026 08:08:02 +0800 Subject: [PATCH] ci: reserve the storage and WAL keys of extra_env regardless of case GreptimeDB reads its environment keys without regard to case, so a lowercase wal or storage segment must be rejected as well. Signed-off-by: jeremyhi --- .github/scripts/oswal-s3-bench.py | 3 ++- tests/perf/test_oswal_s3_bench_scripts.py | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/scripts/oswal-s3-bench.py b/.github/scripts/oswal-s3-bench.py index 76f6f7c0e43..4fa01383355 100644 --- a/.github/scripts/oswal-s3-bench.py +++ b/.github/scripts/oswal-s3-bench.py @@ -109,7 +109,8 @@ def parse_extra_env(text: str) -> dict: raise ValueError(f"extra_env line is not a new K=V: {line!r}") env[name.strip()] = value.strip() for name, value in env.items(): - if not ENV_NAME.fullmatch(name) or name.startswith(RESERVED_ENV) or "\n" in value: + # GreptimeDB matches its environment keys without regard to case. + if not ENV_NAME.fullmatch(name) or name.upper().startswith(RESERVED_ENV) or "\n" in value: raise ValueError(f"extra_env may not set {name!r}") if name in DEPTHS: positive(name, value, 4096) diff --git a/tests/perf/test_oswal_s3_bench_scripts.py b/tests/perf/test_oswal_s3_bench_scripts.py index f43baf12460..cb6fddf7215 100644 --- a/tests/perf/test_oswal_s3_bench_scripts.py +++ b/tests/perf/test_oswal_s3_bench_scripts.py @@ -114,6 +114,8 @@ class PlanTest(unittest.TestCase): {"extra_env": "GREPTIMEDB_STANDALONE__STORAGE__BUCKET=other"}, {"extra_env": "NO_VALUE"}, {"extra_env": "GREPTIMEDB_STANDALONE__WAL__FLUSH_INTERVAL=100ms", "restart": True}, {"extra_env": "GREPTIMEDB_STANDALONE__WAL__SYNC_WRITE=false"}, + {"extra_env": "GREPTIMEDB_STANDALONE__wal__FLUSH_INTERVAL=100ms", "restart": True}, + {"extra_env": "greptimedb_standalone__Storage__bucket=other"}, {"extra_env": "GREPTIMEDB_OSWAL_MAX_SEALED_BATCHES=4", "sweep": "MAX_IN_FLIGHT_CREATES=2,3"}, {"extra_env": "A=1\nA=2"}, {"extra_env": '{"A": true}'}, {"extra_env": "1A=x"}, {"extra_env": "GREPTIMEDB_OSWAL_MAX_IN_FLIGHT_CREATES=many"}, {"configs": "R,X"},