Commit d91bd504 authored by Robert Bradshaw's avatar Robert Bradshaw

Fix infinite recursion in cythonize().

parent a5c06ead
......@@ -278,8 +278,8 @@ class DependencyTree(object):
@cached_method
def package(self, filename):
dir = os.path.dirname(filename)
if os.path.exists(os.path.join(dir, '__init__.py')):
dir = os.path.dirname(os.path.abspath(filename))
if dir != filename and os.path.exists(os.path.join(dir, '__init__.py')):
return self.package(dir) + (os.path.basename(dir),)
else:
return ()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment