You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: sdk/cosmos/azure-cosmos/CHANGELOG.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,8 @@
7
7
#### Breaking Changes
8
8
9
9
#### Bugs Fixed
10
-
10
+
* Fixed bug where client provided session token was not respected when client-side session management was disabled. See [PR 42965](https://github.com/Azure/azure-sdk-for-python/pull/42965)
# At this point, self.client's session is at first token, but we are holding second token. We will now manually use second token in a request on self.client.
73
+
defmanual_token_hook(request):
74
+
# Assert that the header contains the manually provided second token not the client's automatic first token.
#Read an item using the primary client, but manually providing second token. The hook will verify that second token overrides the client's internal first token.
79
+
self.created_collection.read_item(
80
+
item=item2['id'], # Reading the item associated with second token
81
+
partition_key='mypk',
82
+
session_token=manual_session_token, # Manually provide second token
83
+
raw_request_hook=manual_token_hook
84
+
)
85
+
86
+
deftest_manual_session_token_override(self):
87
+
# Create an item to get a valid session token from the response
0 commit comments