collado-mike commented on code in PR #988:
URL: https://github.com/apache/polaris/pull/988#discussion_r1951977774
##########
regtests/client/python/cli/command/catalogs.py:
##########
@@ -199,12 +194,33 @@ def execute(self, api: PolarisDefaultApi) -> None:
default_base_location=new_default_base_location,
additional_properties=new_additional_properties
)
- if (self._has_aws_storage_info() or self._has_azure_storage_info()
or self._has_gcs_storage_info() or
- self.allowed_locations or self.default_base_location):
+
+ if (self._has_aws_storage_info() or self._has_azure_storage_info()
or
+ self._has_gcs_storage_info() or self.allowed_locations):
+ # We must first reconstitute local storage-config related
settings from the existing
+ # catalog to properly construct the complete updated
storage-config
+ updated_storage_info = catalog.storage_config_info
+
+ # In order to apply mutations client-side, we can't just use
the base
+ # _build_storage_config_info helper; instead, each allowed
updatable field defined
+ # in option_tree.py should be applied individually against the
existing
+ # storage_config_info here.
+ if (self.allowed_locations):
+
updated_storage_info.allowed_locations.extend(self.allowed_locations)
Review Comment:
Makes sense to me.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]