diff options
author | Claudiu Popa <pcmanticore@gmail.com> | 2015-12-06 18:41:34 +0200 |
---|---|---|
committer | Claudiu Popa <pcmanticore@gmail.com> | 2015-12-06 18:41:34 +0200 |
commit | b7f934de0d5ded5a120685d92ae07c2eb54b9ff1 (patch) | |
tree | d5ae59bdcf3d8099f907fe854c9ee315bdfa9281 /pylint/test/regrtest_data/beyond_top/__init__.py | |
parent | b700c2f8a0e6b8d61c3abea8d41438f66cd55025 (diff) | |
download | pylint-b7f934de0d5ded5a120685d92ae07c2eb54b9ff1.tar.gz |
Added a new error, 'relative-beyond-top-level'.
This is emitted when a relative import was attempted beyond the top level package.
For instance, if a package has X levels, trying to climb X + n levels with a relative
import, as in `from ..stuff import Stuff`, will result in an error.
Closes issue #588.
Diffstat (limited to 'pylint/test/regrtest_data/beyond_top/__init__.py')
-rw-r--r-- | pylint/test/regrtest_data/beyond_top/__init__.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/pylint/test/regrtest_data/beyond_top/__init__.py b/pylint/test/regrtest_data/beyond_top/__init__.py new file mode 100644 index 0000000..401fe06 --- /dev/null +++ b/pylint/test/regrtest_data/beyond_top/__init__.py @@ -0,0 +1,6 @@ +from ... import Something
+from . import data
+try:
+ from ... import Lala
+except ImportError:
+ pass
\ No newline at end of file |