New submission from Michael Kleehammer <[email protected]>:
The modulefinder module does not handle relative directories properly. The
error I found is when one subpackage attempts to import from a sibling
subpackage using the form
from ..language import (
DirectiveDefinitionNode,
...
)
In this example, it would report "language.DirectiveDefinitionNode" is missing.
It correctly resolves the names when importing modules, but when an import
fails because it is a variable or function, it records the name incorrectly and
cannot filter it out later.
I've attached a small test case and there is a README describing the test and
results.
----------
components: Library (Lib)
files: test.tar.gz
messages: 349268
nosy: mkleehammer
priority: normal
severity: normal
status: open
title: ModuleFinder does not resolve ".." correctly
type: behavior
versions: Python 3.7, Python 3.8
Added file: https://bugs.python.org/file48535/test.tar.gz
_______________________________________
Python tracker <[email protected]>
<https://bugs.python.org/issue37796>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com