diff --git a/pageserver/src/tenant/storage_layer.rs b/pageserver/src/tenant/storage_layer.rs index 2801ff95b1..10dc0d3bdc 100644 --- a/pageserver/src/tenant/storage_layer.rs +++ b/pageserver/src/tenant/storage_layer.rs @@ -1156,6 +1156,7 @@ impl DownloadedLayer { .as_ref() .map_err(|e| { // errors are not clonabled, cannot but stringify + // test_broken_timeline matches this string anyhow::anyhow!("layer loading failed: {e:#}") }) } diff --git a/test_runner/regress/test_broken_timeline.py b/test_runner/regress/test_broken_timeline.py index 57e9413aa3..df87767f8f 100644 --- a/test_runner/regress/test_broken_timeline.py +++ b/test_runner/regress/test_broken_timeline.py @@ -15,7 +15,7 @@ def test_broken_timeline(neon_env_builder: NeonEnvBuilder): env.pageserver.allowed_errors.extend( [ - ".*Failed to load delta layer.*", + ".*layer loading failed:.*", ".*could not find data for key.*", ".*is not active. Current state: Broken.*", ".*will not become active. Current state: Broken.*", @@ -99,7 +99,7 @@ def test_broken_timeline(neon_env_builder: NeonEnvBuilder): # Third timeline will also fail during basebackup, because the layer file is corrupt. # It will fail when we try to read (and reconstruct) a page from it, ergo the error message. # (We don't check layer file contents on startup, when loading the timeline) - with pytest.raises(Exception, match="Failed to load delta layer") as err: + with pytest.raises(Exception, match="layer loading failed:") as err: pg3.start() log.info( f"As expected, compute startup failed for timeline {tenant3}/{timeline3} with corrupt layers: {err}" diff --git a/test_runner/regress/test_tenants_with_remote_storage.py b/test_runner/regress/test_tenants_with_remote_storage.py index 2925f8c2da..eb0121eae3 100644 --- a/test_runner/regress/test_tenants_with_remote_storage.py +++ b/test_runner/regress/test_tenants_with_remote_storage.py @@ -239,9 +239,7 @@ def test_tenant_redownloads_truncated_file_on_startup( assert isinstance(env.remote_storage, LocalFsStorage) - env.pageserver.allowed_errors.append( - ".*removing local file .* because it has unexpected length.*" - ) + env.pageserver.allowed_errors.append(".*removing local file .* because .*") # FIXME: Are these expected? env.pageserver.allowed_errors.append(