AWS CodeArtifact login does not find pip package manager when Python 3 was installed from Homebrew
- Dominant language
- Python
- Stars
- 17.3k
- Forks
- 4.6k
- Avg merge
- 1d 2h
- Merged PRs (30d)
- 13
Description
Confirm by changing [ ] to [x] below to ensure that it's a bug:
- [x] I've gone though the [User Guide](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-welcome.html) and the [API reference](https://docs.aws.amazon.com/cli/latest/reference/)
- [x] I've searched for [previous similar issues](https://github.com/aws/aws-cli/issues) and didn't find any solution
**Describe the bug**
AWS CodeArtifact login does not find pip package manager when Python 3 was installed from Homebrew. This installs current Python 3 to `python3` while legacy Python 2 remains at `python`. Python package manager install pip for Python 3 as `pip3` reflects this.
**SDK version number**
aws-cli/2.2.31 Python/3.9.6 Darwin/20.5.0 source/x86_64 prompt/off
**Platform/OS/Hardware/Device**
macOS Big Sur 11.4 (20F71)
Homebrew 3.2.9
python@3.9: stable 3.9.6 (bottled)
pip 21.2.4 from /usr/local/lib/python3.9/site-packages/pip (python 3.9)
**To Reproduce (observed behavior)**
Login to CodeArtifact repository by using `aws codeartifact login --tool pip`
**Expected behavior**
The tool updates pip configuration file with CodeArtifact credentials.
**Logs/output**
```
$ aws codeartifact login --tool pip ... removed repository and AWS account specific information ...
pip was not found. Please verify installation.
```
**Additional context**
Workaround to the problem is to install another pip with itself using: `pip3 install pip`
Contributor guide
Assessment
This issue has not been assessed yet.