This is an automated email from the ASF dual-hosted git repository.

jshao pushed a commit to branch branch-1.0
in repository https://gitbox.apache.org/repos/asf/gravitino.git


The following commit(s) were added to refs/heads/branch-1.0 by this push:
     new 07ce6f9776 [MINOR] fix(test): Disable `_catalog_cache.clear`  when 
cache is diabled. (#8463)
07ce6f9776 is described below

commit 07ce6f9776d670a05ca7696f42fc206efd6772a7
Author: github-actions[bot] 
<41898282+github-actions[bot]@users.noreply.github.com>
AuthorDate: Mon Sep 8 15:41:50 2025 +0800

    [MINOR] fix(test): Disable `_catalog_cache.clear`  when cache is diabled. 
(#8463)
    
    ### What changes were proposed in this pull request?
    
    Comment the line `fs.operations._catalog_cache.clear()`
    
    ### Why are the changes needed?
    
    _catalog_cache will not initialized when
    `ENABLE_FILESET_METADATA_CACHE_DEFAULT` is changed to false.
    
    ### Does this PR introduce _any_ user-facing change?
    
    N/A
    
    ### How was this patch tested?
    
    Existing tests.
    
    Co-authored-by: Mini Yu <[email protected]>
---
 clients/client-python/tests/integration/test_gvfs_with_s3.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/clients/client-python/tests/integration/test_gvfs_with_s3.py 
b/clients/client-python/tests/integration/test_gvfs_with_s3.py
index 76c56e7c35..3cc97bd344 100644
--- a/clients/client-python/tests/integration/test_gvfs_with_s3.py
+++ b/clients/client-python/tests/integration/test_gvfs_with_s3.py
@@ -278,7 +278,10 @@ class TestGvfsWithS3(TestGvfsWithHDFS):
             **self.conf,
         )
 
-        fs.operations._catalog_cache.clear()
+        if fs.operations._enable_fileset_metadata_cache:
+            fs.operations._fileset_cache.clear()
+            fs.operations._catalog_cache.clear()
+
         s3_fs = fs.operations._get_actual_filesystem(mkdir_dir, None)
         config_kwargs = s3_fs.config_kwargs
         self.assertEqual("virtual", 
config_kwargs.get("s3").get("addressing_style"))

Reply via email to