pip.installed can't check version of pip installed
State:
.install_newer_pip:
pip.installed:
- name: pip==1.2.1
- upgrade: True
Output from second run:
State: - pip
Name: pip==1.2.1
Function: installed
Result: True
Comment: There was no error installing package '"pip==1.2.1"' although it does not show when calling 'pip.freeze'.
Changes: "pip==1.2.1"==???: Installed
Expected output:
State: - pip
Name: pip==1.2.1
Function: installed
Result: True
Comment: Comment: Package already installed
Changes:
Version:
$ salt-minion --versions-report
Salt: 0.15.3
Python: 2.7.3 (default, Apr 10 2013, 06:20:15)
Jinja2: 2.6
M2Crypto: 0.21.1
msgpack-python: 0.1.10
msgpack-pure: Not Installed
pycrypto: 2.4.1
PyYAML: 3.10
PyZMQ: 2.1.11
ZMQ: 2.1.11
Interesting edge case. Thanks for the report.
Wait, can pip actually install itself? I don't actually understand what's going on here. =P
Indeed, it's an edge case. In this case, it was system pip installing the latest pip via pypi. But, I would think that pip could install pip...
pip is definitely able to upgrade itself
Hehe, TIL.
This edge case shouldn't be too difficult.
On 21-08-2013 20:06, David Lindquist wrote:
State:
|.install_newer_pip: pip.installed: - name: pip==1.2.1 - upgrade: True |
Output from second run:
| State: - pip Name: pip==1.2.1 Function: installed Result: True Comment: There was no error installing package '"pip==1.2.1"' although it does not show when calling 'pip.freeze'. Changes: "pip==1.2.1"==???: Installed |
Expected output:
| State: - pip Name: pip==1.2.1 Function: installed Result: True Comment: Comment: Package already installed Changes:
|Version:
|$ salt-minion --versions-report Salt: 0.15.3 Python: 2.7.3 (default, Apr 10 2013, 06:20:15) Jinja2: 2.6 M2Crypto: 0.21.1 msgpack-python: 0.1.10 msgpack-pure: Not Installed pycrypto: 2.4.1 PyYAML: 3.10 PyZMQ: 2.1.11 ZMQ: 2.1.11 |
— Reply to this email directly or view it on GitHub https://github.com/saltstack/salt/issues/6833.
The current develop branch of salt has a lot of changes both to the pip state and module. Would it be possible to confirm if it also happens with latest stable or preferably with the develop git branch?
Pedro Algarvio Pedro Algarvio Email me @algarvio.me mailto:[email protected] // Find me on LinkedIn http://www.linkedin.com/in/pedroalgarvio // Find me on Twitter https://twitter.com/s0undt3ch // Find me on GitHub https://github.com/s0undt3ch // Find me on BitBucket https://bitbucket.org/s0undt3ch // Find me on Ohloh https://www.ohloh.net/accounts/s0undt3ch // Like my work? Tip me on GitTip https://www.gittip.com/s0undt3ch
Still happens with latest stable from the Debian package repo, version 0.16.3-1~bpo70+1~dst.1
State: - pip
Name: pip==1.4.1
Function: installed
Result: True
Comment: There was no error installing package '"pip==1.4.1"' although it does not show when calling 'pip.freeze'.
Changes: "pip==1.4.1"==???: Installed
Yes, latest git develop is what has lot's of changes to the pip state and module, salt 0.16.3 and lower are expected to fail as you stated.
http://jenkins.saltstack.com/job/salt-rs-ubuntu12.04/34/console
Yes, I'm very much aware that I broke all the things by merging that. Trying to figure out how to fix it, thinking I'm going to have to revert for now.
Sorry for just dropping the URL, but your start of day almost matches my end of day and by then I was trying to make the remaining energy last longer ;)
#7143
Thanks for the fix and test case on this, @s0undt3ch !
No worries :smile:
This has been fixed. Closing.