You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 24, 2023. It is now read-only.
$ tar -xzvf dm-ansible-latest.tar.gz
$ mv dm-ansible-latest dm-ansible
$ cd /home/tidb/dm-ansible
$ sudo pip install -r ./requirements.txt
$ ansible --version
What I expect to see:
ansible 2.5.0
What I actually see:
Traceback (most recent call last):
File "/bin/ansible", line 67, in <module>
import ansible.constants as C
File "/usr/lib/python2.7/site-packages/ansible/constants.py", line 17, in <module>
from ansible.config.manager import ConfigManager, ensure_type, get_ini_config_value
File "/usr/lib/python2.7/site-packages/ansible/config/manager.py", line 16, in <module>
from yaml import load as yaml_load
ImportError: No module named yaml
Fixed by:
$ sudo pip install pyyaml --ignore-installed
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
Looking in indexes: http://mirrors.aliyun.com/pypi/simple/
Collecting pyyaml
Downloading http://mirrors.aliyun.com/pypi/packages/9e/a3/1d13970c3f36777c583f136c136f804d70f500168edc1edea6daa7200769/PyYAML-3.13.tar.gz (270kB)
100% |████████████████████████████████| 276kB 3.4MB/s
Installing collected packages: pyyaml
Running setup.py install for pyyaml ... done
Successfully installed pyyaml-3.13
Maybe we should make sure pyyaml is up to date.
The text was updated successfully, but these errors were encountered:
supernan1994
changed the title
Install ansible error because of stale pyyaml
install ansible error because of stale pyyaml
Feb 17, 2019
This is a little strange, as PyYAML is in ansible install dependencies.
We can find Collecting PyYAML (from ansible<2.7.0,>=2.5.0->-r requirements.txt (line 1)) when installing ansible via pip.
Did you install ansible from a clean python env, or whether there are some errors when you run sudo pip install -r ./requirements.txt?
Bug Report
What I have done:
What I expect to see:
What I actually see:
Fixed by:
Maybe we should make sure
pyyaml
is up to date.The text was updated successfully, but these errors were encountered: