chaoflow/mrs.developer — pull request #1 by jaroel (2012-05-09 08:05:21+00:00)
Title: Check for self.root first, because os.path.join doesn't handle None-type very well.

If you install mrs.developer and runs msrd list, you'll get the trace below. os.path.join doesn't check for None type, and self.root is None, so it blows up in you face.

# ./bin/mrsd list
Traceback (most recent call last):
File "./bin/mrsd", line 362, in
mrs.developer.console_script.mrsd()
File "/Users/roel/.buildout/eggs/mrs.developer-0-py2.6.egg/mrs/developer/console_script.py", line 91, in __call__
output = pargs.cmd(pargs=pargs)
File "/Users/roel/.buildout/eggs/mrs.developer-0-py2.6.egg/mrs/developer/distributions.py", line 159, in __call__
if not os.path.isdir(os.path.join(self.root, 'eggs-mrsd')):
File "/Users/roel/workspace/npo.buildout/trunk/../bin/../lib/python2.6/posixpath.py", line 67, in join
elif path == '' or path.endswith('/'):
AttributeError: 'NoneType' object has no attribute 'endswith'