Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Oct 2, 2018. It is now read-only.

[COOK-2702] Fix python::pip fails on changing node.python.prefix_dir #35

Merged
merged 1 commit into from
Apr 24, 2013
Merged

[COOK-2702] Fix python::pip fails on changing node.python.prefix_dir #35

merged 1 commit into from
Apr 24, 2013

Conversation

tk0miya
Copy link
Contributor

@tk0miya tk0miya commented Apr 4, 2013

This is a fix for COOK-2702

@boris317
Copy link

boris317 commented Apr 5, 2013

I just ran into this same issue. This is exactly how I fixed the problem as well.

jtimberman pushed a commit that referenced this pull request Apr 24, 2013
[COOK-2702] Fix python::pip fails on changing node.python.prefix_dir
@jtimberman jtimberman merged commit f0fb2a4 into poise:master Apr 24, 2013
whitekid added a commit to whitekid/chef-python that referenced this pull request Apr 26, 2013
@schisamo
Copy link
Contributor

schisamo commented May 1, 2013

@jtimberman @tk0miya this cookbook is totally broken now on Ubuntu. Was this converged with Test Kitchen?

It fails for me:
https://gist.github.com/schisamo/0c8949a60bf04d255eb4

@@ -23,7 +23,7 @@
elsif platform_family?("smartos")
pip_binary = "/opt/local/bin/pip"
else
pip_binary = "/usr/local/bin/pip"
pip_binary = "#{node['python']['prefix_dir']}/bin/pip"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jtimberman @tk0miya So on Ubuntu python is at /usr/bin/python and pip installs into /usr/local/bin/pip so this change causes this recipe to stop being idempotent.

@tk0miya
Copy link
Contributor Author

tk0miya commented May 2, 2013

Sorry, I fixed problem of ubuntu.
and, i passed test-kitchen now.

please merge it again.

@schisamo
Copy link
Contributor

schisamo commented May 2, 2013

@tk0miya so I'm wondering if we should rethink this. The huge set of if/else statements for each platform feels like a smell.

@stevendanna
Copy link
Contributor

Not just multiple if/else statements but if/else statements that affect the same value split across two different files. Agree that we need to fix before the release, but lets aim to clean up this logic rather than just add to it.

jtimberman pushed a commit that referenced this pull request May 3, 2013
…-prefix_dir"

This reverts commit f0fb2a4, reversing
changes made to 4afbc55.
@jtimberman
Copy link

I concur with @schisamo and @stevendanna. We actually already had the following ticket, which was to fix Debian awhile back, but it seems the best solution for that ticket is adding new attributes for pip and virtualenv. As such, I will close this ticket in favor of that one.

http://tickets.opscode.com/browse/COOK-1763

@tk0miya
Copy link
Contributor Author

tk0miya commented May 3, 2013

I understand. i'm waiting for that :-)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants