Repository: globus/globus-sdk-python

Issue:
Missing f-string in parameterized url
When attempting to use the endpoint_manager_task_successful_transfers method, my call failed with 400 (despite providing a valid UUID task_id arg as a string).

https://github.com/globus/globus-sdk-python/blob/main/src/globus_sdk/services/transfer/client.py#L2162

Discussion:

Patch:
diff --git a/changelog.d/20230214_193302_sirosen_fix_missing_fstring.rst b/changelog.d/20230214_193302_sirosen_fix_missing_fstring.rst
new file mode 100644
index 00000000..e9752fde
--- /dev/null
+++ b/changelog.d/20230214_193302_sirosen_fix_missing_fstring.rst
@@ -0,0 +1,2 @@
+* Fix a typo in ``TransferClient.endpoint_manager_task_successful_transfers``
+  which prevented calls from being made correctly (:pr:`NUMBER`)
diff --git a/src/globus_sdk/services/transfer/client.py b/src/globus_sdk/services/transfer/client.py
index 2fddc5f2..89f148f7 100644
--- a/src/globus_sdk/services/transfer/client.py
+++ b/src/globus_sdk/services/transfer/client.py
@@ -2159,7 +2159,7 @@ class TransferClient(client.BaseClient):
             query_params["marker"] = marker
         return IterableTransferResponse(
             self.get(
-                "endpoint_manager/task/{task_id}/successful_transfers",
+                f"endpoint_manager/task/{task_id}/successful_transfers",
                 query_params=query_params,
             )
         )


Test patch:
diff --git a/src/globus_sdk/_testing/data/transfer/endpoint_manager_task_successful_transfers.py b/src/globus_sdk/_testing/data/transfer/endpoint_manager_task_successful_transfers.py
new file mode 100644
index 00000000..2610ddb3
--- /dev/null
+++ b/src/globus_sdk/_testing/data/transfer/endpoint_manager_task_successful_transfers.py
@@ -0,0 +1,24 @@
+from globus_sdk._testing.models import RegisteredResponse, ResponseSet
+
+from ._common import TASK_ID
+
+RESPONSES = ResponseSet(
+    metadata={"task_id": TASK_ID},
+    default=RegisteredResponse(
+        service="transfer",
+        method="GET",
+        path=f"/endpoint_manager/task/{TASK_ID}/successful_transfers",
+        json={
+            "DATA_TYPE": "successful_transfers",
+            "marker": 0,
+            "next_marker": 93979,
+            "DATA": [
+                {
+                    "destination_path": "/path/to/destination",
+                    "source_path": "/path/to/source",
+                    "DATA_TYPE": "successful_transfer",
+                }
+            ],
+        },
+    ),
+)
diff --git a/tests/functional/services/transfer/endpoint_manager/test_endpoint_manager_task_successful_transfers.py b/tests/functional/services/transfer/endpoint_manager/test_endpoint_manager_task_successful_transfers.py
index 0412b34b..528a2977 100644
--- a/tests/functional/services/transfer/endpoint_manager/test_endpoint_manager_task_successful_transfers.py
+++ b/tests/functional/services/transfer/endpoint_manager/test_endpoint_manager_task_successful_transfers.py
@@ -1,6 +1,10 @@
-import pytest
+from globus_sdk._testing import load_response
 
 
-@pytest.mark.xfail
-def test_endpoint_manager_task_successful_transfers():
-    raise NotImplementedError
+def test_endpoint_manager_task_successful_transfers(client):
+    meta = load_response(client.endpoint_manager_task_successful_transfers).metadata
+
+    response = client.endpoint_manager_task_successful_transfers(meta["task_id"])
+
+    assert response.http_status == 200
+    assert response["DATA_TYPE"] == "successful_transfers"