Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I have a small note to contribute. While attempting to follow-along on this post, I began with three installs of Python:</p> <ol> <li>The default Apple Python 2.5.1 located at: /usr/bin/python</li> <li>A version located: /Library/Frameworks/Python.framework/Versions/2.7</li> <li>And a Macport version located: /opt/local/bin/python2.6</li> </ol> <p>My trouble was that:</p> <pre><code>$ python </code></pre> <p>would always default to the 2.7 when I needed it to use the Macports version. The following did not help:</p> <pre><code>$ sudo python_select python26 </code></pre> <p>I even removed the 2.7 version which caused only an error.</p> <p>I figured out I needed to change the default path to the Macports version using the following:</p> <pre><code>$ PATH=$PATH\:/opt/local/bin ; export PATH </code></pre> <p>And then reinitiate the ports, etc.</p> <p>Finally, I was not able to reference the scrapy-ctl.py file by default through these instructions so I had to reference the scrapy-ctl.py file directly </p> <pre><code>/opt/local/Library/Frameworks/Python.framework/Versions/2.6/bin/scrapy-ctl.py </code></pre> <p><strong>UPDATE</strong></p> <p>A quick addendum to this post with instructions to create the link, found <a href="http://doc.scrapy.org/intro/install.html#intro-install-dev" rel="nofollow noreferrer">on the Scrapy site</a> (#2 and #3).</p> <p>Starting with #2, "Add Scrapy to your Python Path"</p> <pre><code>sudo ln -s /opt/local/Library/Frameworks/Python.framework/Versions/2.6/bin/scrapy-ctl.py /opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/scrapy </code></pre> <p>And #3, "Make the scrapy command available"</p> <pre><code>sudo ln -s /opt/local/Library/Frameworks/Python.framework/Versions/2.6/bin/scrapy-ctl.py /usr/local/bin/scrapy </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload