Skip to content

Commit

Permalink
Added continuous-token as response (#1243)
Browse files Browse the repository at this point in the history
* Initial Commit

* Run style fix

* Internal Commit

* Local changes reverted

* Run style Changes

* Launch js reverted

* Update client.py

* Update invoke.py
  • Loading branch information
roshan-sy committed Feb 17, 2022
1 parent 628525c commit ec5f4ee
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -306,3 +306,4 @@ paket-files/
# Except for the release folders which contains vsts release code
!azure-devops/azext_devops/devops_sdk/*/release/
azure-devops/azext_devops/devops_sdk/*/release/release/__pycache__
.azure/devcliextensions
4 changes: 2 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"name": "Azure DevOps CLI Debug (Integrated Console)",
"type": "python",
"request": "launch",
"pythonPath": "${config:python.pythonPath}",
"python": "${command:python.interpreterPath}",
"program": "${workspaceRoot}/scripts/run_az.py",
"cwd": "${workspaceRoot}/azure-devops/",
"args": [
Expand All @@ -25,7 +25,7 @@
"WaitOnNormalExit",
"RedirectOutput"
],
"debugStdLib": true,
"justMyCode": false,
"preLaunchTask": "BuildWheel",
"env": {
"AZURE_EXTENSION_DIR": "${workspaceRoot}"
Expand Down
4 changes: 3 additions & 1 deletion azure-devops/azext_devops/dev/team/invoke.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,9 @@ def invoke(area=None, resource=None,
logger.info('Content type header is None.')
is_content_available = False
elif 'json' in response.headers.get("content-type") and not out_file:
return response.json()
response_dict = response.json()
response_dict["continuation_token"] = response.headers.get('X-MS-ContinuationToken')
return response_dict

# Only handle out file scenario if the content is available (content-type is not None)
if is_content_available:
Expand Down

0 comments on commit ec5f4ee

Please sign in to comment.