@@ -1234,7 +1234,7 @@ def clear_global_keys(
12341234 global_keys : List [str ],
12351235 timeout_seconds = 60 ) -> Dict [str , Union [str , List [Any ]]]:
12361236 """
1237- Gets data row ids for a list of global keys.
1237+ Clears global keys for the data rows tha correspond to the global keys provided .
12381238
12391239 Args:
12401240 A list of global keys
@@ -1244,11 +1244,10 @@ def clear_global_keys(
12441244 'Status' contains the outcome of this job. It can be one of
12451245 'Success', 'Partial Success', or 'Failure'.
12461246
1247- 'Results' contains a list of data row ids successfully fetchced. It may
1248- not necessarily contain all data rows requested.
1247+ 'Results' contains a list global keys that were successfully cleared.
12491248
1250- 'Errors' contains a list of global_keys that could not be fetched, along
1251- with the failure reason
1249+ 'Errors' contains a list of global_keys correspond to the data rows that could not be
1250+ modified, accessed by the user, or not found.
12521251 Examples:
12531252 >>> job_result = client.get_data_row_ids_for_global_keys(["key1","key2"])
12541253 >>> print(job_result['status'])
@@ -1307,12 +1306,9 @@ def _format_failed_rows(rows: List[str],
13071306 _format_failed_rows (data ['accessDeniedGlobalKeys' ],
13081307 "Denied access to modify data row matching provided global key" ))
13091308
1310- # Invalid results may contain empty string, so we must filter
1311- # them prior to checking for PARTIAL_SUCCESS
1312- filtered_results = list (filter (lambda r : r != '' , results ))
13131309 if not errors :
13141310 status = CollectionJobStatus .SUCCESS .value
1315- elif errors and len (filtered_results ) > 0 :
1311+ elif errors and len (results ) > 0 :
13161312 status = CollectionJobStatus .PARTIAL_SUCCESS .value
13171313 else :
13181314 status = CollectionJobStatus .FAILURE .value
0 commit comments