We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d513711 commit c9b27d0Copy full SHA for c9b27d0
pulsar/managers/util/tes.py
@@ -41,10 +41,13 @@ def ensure_tes_client() -> None:
41
42
def tes_client_from_dict(destination_params: Dict[str, Any]) -> TesClient:
43
# TODO: implement funnel's basic auth in pydantic-tes and expose it here.
44
- tes_url = destination_params["tes_url"]
45
- return TesClient(
46
- url=tes_url,
47
- )
+ tes_url = destination_params.get("tes_url")
+ token = destination_params.get("private_token")
+ headers = {}
+ if token:
48
+ headers["Authorization"] = f"Bearer {token}"
49
+
50
+ return TesClient(url=tes_url, headers=headers)
51
52
53
def tes_resources(destination_params: Dict[str, Any]) -> TesResources:
0 commit comments