Skip to content

Commit

Permalink
deprecate re-installation of AWS CLI from source in the pytest action
Browse files Browse the repository at this point in the history
  • Loading branch information
wenh06 committed Jan 15, 2025
1 parent fb7df6f commit 4dfdfb1
Showing 1 changed file with 23 additions and 21 deletions.
44 changes: 23 additions & 21 deletions .github/workflows/run-pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,27 +60,29 @@ jobs:
python setup.py install_egg_info # Workaround https://github.com/pypa/pip/issues/4537
python -m pip install -e .[dev]
python -m pip freeze
- name: Re-install AWS cli v2 from source
# AWS cli v2 is pre-installed, but via executable, which does not provide python interface
# Installing from source will provide python interface
run: |
aws --version
which aws
readlink -f $(which aws)
echo "Uninstalling aws-cli v2"
sudo rm /usr/local/bin/aws
sudo rm /usr/local/bin/aws_completer
sudo rm -rf /usr/local/aws-cli
git clone https://github.com/aws/aws-cli.git
cd aws-cli
git checkout v2
echo "Installing aws-cli v2"
pip install -r requirements-dev.txt
pip install -e .
echo "Checking aws-cli installation"
aws --version
which aws
readlink -f $(which aws)
# - name: Re-install AWS cli v2 from source
# # deprecated
# # AWS cli v2 is pre-installed, but via executable, which does not provide python interface
# # Installing from source will provide python interface
# run: |
# aws --version
# which aws
# readlink -f $(which aws)
# echo "Uninstalling aws-cli v2"
# sudo rm /usr/local/bin/aws
# sudo rm /usr/local/bin/aws_completer
# sudo rm -rf /usr/local/aws-cli
# git clone https://github.com/aws/aws-cli.git
# cd aws-cli
# git checkout v2
# echo "Installing aws-cli v2"
# pip install -r requirements-dev.txt
# pip install -e .
# echo "Checking aws-cli installation"
# pip list
# aws --version
# which aws
# readlink -f $(which aws)
- name: List installed Python packages
run: |
python -m pip list
Expand Down

0 comments on commit 4dfdfb1

Please sign in to comment.