diff options
| author | Sylvain Th?nault <sylvain.thenault@logilab.fr> | 2011-07-08 18:11:04 +0200 |
|---|---|---|
| committer | Sylvain Th?nault <sylvain.thenault@logilab.fr> | 2011-07-08 18:11:04 +0200 |
| commit | 80fea3a8df4d6f1c537f1a4d0ee74c5bd17f7a2d (patch) | |
| tree | 18916838641e587f432b8d509770f0fda9d3729d /inference.py | |
| parent | 5d857a5ca98da96d2f56ed9dc73ea968b7798267 (diff) | |
| download | astroid-80fea3a8df4d6f1c537f1a4d0ee74c5bd17f7a2d.tar.gz | |
test and fix relative import inference pb, detected with python 3
Diffstat (limited to 'inference.py')
| -rw-r--r-- | inference.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/inference.py b/inference.py index edc7183..e2411c0 100644 --- a/inference.py +++ b/inference.py @@ -199,7 +199,7 @@ def infer_from(self, context=None, asname=True): try: context = copy_context(context) context.lookupname = name - return _infer_stmts(module.getattr(name), context) + return _infer_stmts(module.getattr(name, ignore_locals=module is self.root()), context) except NotFoundError: raise InferenceError(name) nodes.From.infer = path_wrapper(infer_from) |
