Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions .azure-pipelines/templates/azdev_setup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,9 @@ steps:
python -m venv env
chmod +x env/bin/activate
source ./env/bin/activate
# clone azure-cli
git clone -q --single-branch -b dev https://github.com/Azure/azure-cli.git ../azure-cli
python -m pip install -U pip
# azdev 0.2.11b1 (decouples extension metadata from wheel==0.30.0) tho it is not on PyPI yet.
# Pinned to a specific azure-cli-dev-tools commit (not @dev) for reproducible builds
# until the pre-release is published; then switch this back to:
# pip install --upgrade "azdev==0.2.11b1"
pip install --upgrade "git+https://github.com/Azure/azure-cli-dev-tools.git@49390f30c6a822620d2fbdf88889c4445d22666f#egg=azdev"
pip install --upgrade "azdev==0.2.12"
azdev --version
azdev setup -c $CLI_REPO_PATH -r $CLI_EXT_REPO_PATH --debug
pip list -v
Expand Down
2 changes: 1 addition & 1 deletion .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ This checklist is used to make sure that common guidelines for a pull request ar
### General Guidelines

- [ ] Have you run `azdev style <YOUR_EXT>` locally? (`pip install azdev` required)
- [ ] Have you run `python scripts/ci/test_index.py -q` locally? (`azdev` required; see `.azure-pipelines/templates/azdev_setup.yml` for the install command until `azdev==0.2.11b1` is on PyPI)
- [ ] Have you run `python scripts/ci/test_index.py -q` locally? (`pip install azdev` required)
- [ ] My extension version conforms to the [Extension version schema](https://github.com/Azure/azure-cli/blob/release/doc/extensions/versioning_guidelines.md)

For new extensions:
Expand Down
6 changes: 2 additions & 4 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,8 @@ jobs:
#!/usr/bin/env bash
set -ev
# test_index.py imports scripts/ci/util.py, which reads wheel metadata via azdev's
# pkginfo-based metadata module (decoupled from wheel==0.30.0), so azdev must be
# installed here. Install from the merged azure-cli-dev-tools source until azdev
# 0.2.11b1 is published to PyPI, then switch this to: pip install --upgrade "azdev==0.2.11b1"
pip install --upgrade "git+https://github.com/Azure/azure-cli-dev-tools.git@49390f30c6a822620d2fbdf88889c4445d22666f#egg=azdev"
# pkginfo-based metadata module (decoupled from wheel==0.30.0), so azdev must be installed here.
pip install --upgrade "azdev==0.2.12"
pip install requests packaging setuptools
export CI="ADO"
python ./scripts/ci/test_index.py -v
Expand Down
6 changes: 5 additions & 1 deletion scripts/ci/update_index.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,11 @@ def main():
ext_dir = tempfile.mkdtemp(dir=extensions_dir)
whl_cache_dir = tempfile.mkdtemp()
whl_cache = {}
ext_file = get_whl_from_url(whl_path, extension_name, whl_cache_dir, whl_cache)
# Download to the real wheel filename (ending in .whl): get_ext_metadata now
# reads metadata via pkginfo, which requires a .whl-named file. Passing the
# extension name (e.g. "ssh") produced an extension-less temp file that
# pkginfo rejects with "Not a known wheel archive format".
ext_file = get_whl_from_url(whl_path, whl_path.split('/')[-1], whl_cache_dir, whl_cache)

with open('./src/index.json', 'r') as infile:
curr_index = json.loads(infile.read())
Expand Down
Loading