Skip to content

Commit 090b6e8

Browse files
committed
more
1 parent e440727 commit 090b6e8

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

appium/webdriver/appium_connection.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@ class AppiumConnection(RemoteConnection):
3535
def get_remote_connection_headers(cls, parsed_url: 'ParseResult', keep_alive: bool = True) -> Dict[str, Any]:
3636
"""Override get_remote_connection_headers in RemoteConnection"""
3737
headers = RemoteConnection.get_remote_connection_headers(parsed_url, keep_alive=keep_alive)
38-
# e.g. appium/0.49 (selenium/3.141.0 (python linux))
39-
# headers['User-Agent'] = f'{PREFIX_HEADER}{library_version()} ({headers["User-Agent"]})'
4038
if parsed_url.path.endswith('/session'):
4139
# https://github.com/appium/appium-base-driver/pull/400
42-
headers['X-Idempotency-Key'] = str(uuid.uuid4())
40+
RemoteConnection.extra_headers = {'X-Idempotency-Key': str(uuid.uuid4())}
41+
else:
42+
RemoteConnection.extra_headers = {}
4343

4444
return headers

0 commit comments

Comments
 (0)