pycharm安装ansible模块
在pycharm中通过pip install ansible==2.9时遇到报错:
error: can't copy 'lib\ansible\module_utils\ansible_release.py': doesn't exist or not a regular file
解决方法:
- Download the latest zip release version from github (e.g. https://github.com/ansible/ansible/archive/v2.9.2.zip). Note, must be zip version, because the tar.gz has symbolic links in it).
- Unzip to (e.g.) C:\Temp\ansible-2.9.2
- Remove the symlink dependency by changing setup.py to return immediately from _maintain_symlinks:
def_maintain_symlinks(symlink_type, base_path): return
- cd C:\Temp\ansible-2.9.2
- c:\Python38\python.exe setup.py install