larryng/narwal — pull request #3 by legoktm (2012-05-10 00:44:52+00:00)
Title: Fix bug if requests module was not installed

When trying to install with pip or setup.py, I encountered the following error:
```
Traceback (most recent call last):
File "setup.py", line 5, in
from narwal import __version__
File "/Users/legoktm/projects/narwal/narwal/__init__.py", line 3, in
from .reddit import connect, Reddit
File "/Users/legoktm/projects/narwal/narwal/reddit.py", line 5, in
import requests
ImportError: No module named requests
```
When importing narwal to get the version number, it imported requests, which would only be installed after narwal was, so it failed.

My patch modifies sys.path so the narwal directory is added so const.py is imported directly, without importing the entire narwal directory and requests.