mchades commented on code in PR #12442:
URL: https://github.com/apache/gravitino/pull/12442#discussion_r3802874552


##########
clients/client-python/gravitino/client/generic_tag.py:
##########
@@ -113,38 +130,53 @@ def associated_objects(self) -> Tag.AssociatedObjects:
         """
         return self
 
-    def objects(self) -> list[MetadataObject]:
+    def objects(self, value: Optional[str] = None) -> list[MetadataObject]:
         """
         Retrieve the list of objects that are associated with this tag.
 
+        Args:
+            value: The optional exact assignment value filter.
+
         Returns:
             list[MetadataObject]: The list of objects that are associated with 
this tag.
         """
+        params = {}
+        if value is not None:
+            Precondition.check_argument(
+                value.strip() != "" and len(value) <= 256,
+                "value must not be empty or longer than 256 characters",
+            )
+            params["value"] = value
+
         url = self.API_LIST_OBJECTS_ENDPOINT.format(
             self._metalake,
             encode_string(self.name()),
         )
 
-        response = self.get_response(url, TAG_ERROR_HANDLER)
+        response = self.get_response(url, TAG_ERROR_HANDLER, params)

Review Comment:
   [P2] Preserve the existing two-argument `get_response` hook
   
   Even when `value` is `None`, this now passes a third positional argument. 
`get_response` is a public hook explicitly documented for testing convenience, 
so an existing subclass or test double that overrides the previous 
`get_response(self, url, error_handler)` works at the merge-base but now makes 
`objects()` fail with `TypeError` before the hook is reached. Please keep the 
unfiltered path calling the two-argument hook (and make `params` optional or 
introduce a separate helper); the filtered path can use the new parameter.



-- 
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]

Reply via email to