Skip to content

Commit

Permalink
fix flaky id in polling (Azure#19921)
Browse files Browse the repository at this point in the history
  • Loading branch information
kristapratico authored Jul 23, 2021
1 parent f0f09cf commit ee646d7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ def _current_body(self):

def _get_id_from_headers(self):
# type: () -> str
return self._pipeline_response.http_response.headers[
return self._initial_response.http_response.headers[
"Operation-Location"
].split("/batches/")[1]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def _current_body(self) -> _TranslationStatus:
return _TranslationStatus.deserialize(self._pipeline_response)

def _get_id_from_headers(self) -> str:
return self._pipeline_response.http_response.headers[
return self._initial_response.http_response.headers[
"Operation-Location"
].split("/batches/")[1]

Expand Down

0 comments on commit ee646d7

Please sign in to comment.