<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: How to Add Locations to Python Path for Reusable Django Apps</title>
	<atom:link href="http://codespatter.com/2009/04/10/how-to-add-locations-to-python-path-for-reusable-django-apps/feed/" rel="self" type="application/rss+xml" />
	<link>http://codespatter.com/2009/04/10/how-to-add-locations-to-python-path-for-reusable-django-apps/</link>
	<description></description>
	<lastBuildDate>Sun, 25 Mar 2012 22:58:44 -0500</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
	<item>
		<title>By: Jdawg</title>
		<link>http://codespatter.com/2009/04/10/how-to-add-locations-to-python-path-for-reusable-django-apps/comment-page-1/#comment-15260</link>
		<dc:creator>Jdawg</dc:creator>
		<pubDate>Wed, 22 Jun 2011 17:18:15 +0000</pubDate>
		<guid isPermaLink="false">http://codespatter.com/?p=261#comment-15260</guid>
		<description>Edit: I still needed to modify &lt;a href=&quot;http://settings.py&quot; rel=&quot;nofollow&quot;&gt;settings.py&lt;/a&gt; after all, to allow &lt;a href=&quot;http://manage.py&quot; rel=&quot;nofollow&quot;&gt;manage.py&lt;/a&gt; syncdb and &lt;a href=&quot;http://manage.py&quot; rel=&quot;nofollow&quot;&gt;manage.py&lt;/a&gt; runserver to know that the apps folder should be added. Works like a charm, thanks again for this post!</description>
		<content:encoded><![CDATA[<p>Edit: I still needed to modify <a href="http://settings.py" rel="nofollow">settings.py</a> after all, to allow <a href="http://manage.py" rel="nofollow">manage.py</a> syncdb and <a href="http://manage.py" rel="nofollow">manage.py</a> runserver to know that the apps folder should be added. Works like a charm, thanks again for this post!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jdawg</title>
		<link>http://codespatter.com/2009/04/10/how-to-add-locations-to-python-path-for-reusable-django-apps/comment-page-1/#comment-15259</link>
		<dc:creator>Jdawg</dc:creator>
		<pubDate>Wed, 22 Jun 2011 17:12:16 +0000</pubDate>
		<guid isPermaLink="false">http://codespatter.com/?p=261#comment-15259</guid>
		<description>Great post. Under mod_wsgi was able to do this without editing &lt;a href=&quot;http://settings.py&quot; rel=&quot;nofollow&quot;&gt;settings.py&lt;/a&gt; at all, just my .wsgi file, which looks like:&lt;br&gt;&lt;br&gt;import os&lt;br&gt;import sys&lt;br&gt;&lt;br&gt;#Calculate the path based on the location of the WSGI script.&lt;br&gt;apache_configuration= os.path.dirname(__file__)&lt;br&gt;&lt;br&gt;project = os.path.dirname(apache_configuration)&lt;br&gt;if project not in sys.path:&lt;br&gt;    sys.path.append(project)&lt;br&gt;&lt;br&gt;# Add re-usable apps directory to path&lt;br&gt;apps    = project + &quot;/apps&quot;&lt;br&gt;sys.path.append(apps)&lt;br&gt;&lt;br&gt;os.environ[&#039;DJANGO_SETTINGS_MODULE&#039;] = &#039;settings&#039;&lt;br&gt;&lt;br&gt;import django.core.handlers.wsgi&lt;br&gt;application = django.core.handlers.wsgi.WSGIHandler()&lt;br&gt;&lt;br&gt;# To Debug path issues&lt;br&gt;#print &gt;&gt; sys.stderr, sys.path</description>
		<content:encoded><![CDATA[<p>Great post. Under mod_wsgi was able to do this without editing <a href="http://settings.py" rel="nofollow">settings.py</a> at all, just my .wsgi file, which looks like:</p>
<p>import os<br />import sys</p>
<p>#Calculate the path based on the location of the WSGI script.<br />apache_configuration= os.path.dirname(__file__)</p>
<p>project = os.path.dirname(apache_configuration)<br />if project not in sys.path:<br />    sys.path.append(project)</p>
<p># Add re-usable apps directory to path<br />apps    = project + &#8220;/apps&#8221;<br />sys.path.append(apps)</p>
<p>os.environ[&#39;DJANGO_SETTINGS_MODULE&#39;] = &#39;settings&#39;</p>
<p>import django.core.handlers.wsgi<br />application = django.core.handlers.wsgi.WSGIHandler()</p>
<p># To Debug path issues<br />#print &gt;&gt; sys.stderr, sys.path</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: new to django</title>
		<link>http://codespatter.com/2009/04/10/how-to-add-locations-to-python-path-for-reusable-django-apps/comment-page-1/#comment-15243</link>
		<dc:creator>new to django</dc:creator>
		<pubDate>Tue, 11 Jan 2011 04:30:30 +0000</pubDate>
		<guid isPermaLink="false">http://codespatter.com/?p=261#comment-15243</guid>
		<description>Thank you! I was struggling with why I couldn&#039;t get this to work in Eclipse. Now I&#039;m golden.</description>
		<content:encoded><![CDATA[<p>Thank you! I was struggling with why I couldn&#39;t get this to work in Eclipse. Now I&#39;m golden.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel Gregoire</title>
		<link>http://codespatter.com/2009/04/10/how-to-add-locations-to-python-path-for-reusable-django-apps/comment-page-1/#comment-15235</link>
		<dc:creator>Daniel Gregoire</dc:creator>
		<pubDate>Tue, 16 Nov 2010 14:14:14 +0000</pubDate>
		<guid isPermaLink="false">http://codespatter.com/?p=261#comment-15235</guid>
		<description>Thanks for this. Novice python and django programmer, was struggling for how to get a separate &#039;apps&#039; folder in my pythonpath for my django &lt;a href=&quot;http://settings.py&quot; rel=&quot;nofollow&quot;&gt;settings.py&lt;/a&gt; file.</description>
		<content:encoded><![CDATA[<p>Thanks for this. Novice python and django programmer, was struggling for how to get a separate &#39;apps&#39; folder in my pythonpath for my django <a href="http://settings.py" rel="nofollow">settings.py</a> file.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

