forked from VimPlug/jedi
rename non-cycling imports to 'from jedi import ..'
This commit is contained in:
23
jedi/api.py
23
jedi/api.py
@@ -13,23 +13,22 @@ import re
|
||||
import os
|
||||
import warnings
|
||||
|
||||
import parsing
|
||||
import parsing_representation as pr
|
||||
from jedi import parsing
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import debug
|
||||
from jedi import settings
|
||||
from jedi import helpers
|
||||
from jedi import common
|
||||
from jedi import cache
|
||||
from jedi import api_classes
|
||||
from jedi import modules
|
||||
from jedi import keywords
|
||||
from jedi._compatibility import next, unicode
|
||||
import evaluate_representation as er
|
||||
import dynamic
|
||||
import imports
|
||||
import evaluate
|
||||
import modules
|
||||
import debug
|
||||
import settings
|
||||
import keywords
|
||||
import helpers
|
||||
import common
|
||||
import builtin
|
||||
import api_classes
|
||||
import cache
|
||||
|
||||
from _compatibility import next, unicode
|
||||
|
||||
|
||||
class NotFoundError(Exception):
|
||||
|
||||
@@ -9,16 +9,16 @@ import os
|
||||
import warnings
|
||||
import functools
|
||||
|
||||
from _compatibility import unicode, next
|
||||
import cache
|
||||
from jedi._compatibility import unicode, next
|
||||
from jedi import recursion
|
||||
from jedi import settings
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import keywords
|
||||
from jedi import cache
|
||||
import dynamic
|
||||
import recursion
|
||||
import settings
|
||||
import evaluate
|
||||
import imports
|
||||
import parsing_representation as pr
|
||||
import evaluate_representation as er
|
||||
import keywords
|
||||
|
||||
|
||||
def _clear_caches():
|
||||
|
||||
@@ -22,7 +22,7 @@ possible to access functions like ``list`` and ``int`` directly, the same way
|
||||
"""
|
||||
|
||||
from __future__ import with_statement
|
||||
from _compatibility import exec_function, is_py3k
|
||||
from jedi._compatibility import exec_function, is_py3k
|
||||
|
||||
import re
|
||||
import sys
|
||||
@@ -32,11 +32,11 @@ if is_py3k:
|
||||
import types
|
||||
import inspect
|
||||
|
||||
import common
|
||||
import debug
|
||||
import parsing
|
||||
from jedi import common
|
||||
from jedi import debug
|
||||
from jedi import parsing
|
||||
from jedi import modules
|
||||
import evaluate
|
||||
import modules
|
||||
|
||||
|
||||
class BuiltinModule(modules.CachedModule):
|
||||
|
||||
@@ -23,9 +23,9 @@ import os
|
||||
import sys
|
||||
import pickle
|
||||
|
||||
from _compatibility import json
|
||||
import settings
|
||||
import debug
|
||||
from jedi._compatibility import json
|
||||
from jedi import settings
|
||||
from jedi import debug
|
||||
|
||||
# memoize caches will be deleted after every action
|
||||
memoize_caches = []
|
||||
|
||||
@@ -4,9 +4,9 @@ import contextlib
|
||||
import functools
|
||||
import tokenize
|
||||
|
||||
from _compatibility import next, reraise
|
||||
import debug
|
||||
import settings
|
||||
from jedi._compatibility import next, reraise
|
||||
from jedi import debug
|
||||
from jedi import settings
|
||||
|
||||
|
||||
class MultiLevelStopIteration(Exception):
|
||||
|
||||
@@ -16,10 +16,10 @@ annotations.
|
||||
|
||||
import re
|
||||
|
||||
import cache
|
||||
from jedi import cache
|
||||
from jedi import parsing
|
||||
import evaluate
|
||||
import evaluate_representation as er
|
||||
import parsing
|
||||
|
||||
DOCSTRING_PARAM_PATTERNS = [
|
||||
r'\s*:type\s+%s:\s*([^\n]+)', # Sphinx
|
||||
|
||||
@@ -55,16 +55,16 @@ from __future__ import with_statement
|
||||
|
||||
import os
|
||||
|
||||
import cache
|
||||
import parsing_representation as pr
|
||||
import evaluate_representation as er
|
||||
import modules
|
||||
from jedi import cache
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import modules
|
||||
from jedi import settings
|
||||
from jedi import debug
|
||||
from jedi import api_classes
|
||||
from jedi import fast_parser
|
||||
import evaluate
|
||||
import settings
|
||||
import debug
|
||||
import imports
|
||||
import api_classes
|
||||
import fast_parser
|
||||
import evaluate_representation as er
|
||||
|
||||
# This is something like the sys.path, but only for searching params. It means
|
||||
# that this is the order in which Jedi searches params.
|
||||
|
||||
@@ -73,16 +73,16 @@ from _compatibility import next, hasattr, is_py3k, unicode, reraise
|
||||
import sys
|
||||
import itertools
|
||||
|
||||
import common
|
||||
import cache
|
||||
import parsing_representation as pr
|
||||
from jedi import common
|
||||
from jedi import cache
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import debug
|
||||
from jedi import recursion
|
||||
import docstrings
|
||||
import evaluate_representation as er
|
||||
import debug
|
||||
import builtin
|
||||
import imports
|
||||
import recursion
|
||||
import dynamic
|
||||
import docstrings
|
||||
|
||||
|
||||
def get_defined_names_for_position(scope, position=None, start_scope=None):
|
||||
|
||||
@@ -13,17 +13,17 @@ import copy
|
||||
import itertools
|
||||
|
||||
from _compatibility import property, use_metaclass, next, hasattr
|
||||
import parsing_representation as pr
|
||||
import imports
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import cache
|
||||
from jedi import helpers
|
||||
from jedi import debug
|
||||
from jedi import common
|
||||
from jedi import recursion
|
||||
import docstrings
|
||||
import cache
|
||||
import imports
|
||||
import evaluate
|
||||
import builtin
|
||||
import dynamic
|
||||
import helpers
|
||||
import recursion
|
||||
import debug
|
||||
import evaluate
|
||||
import common
|
||||
|
||||
|
||||
class DecoratorNotFound(LookupError):
|
||||
|
||||
@@ -6,11 +6,11 @@ finished (and still not working as I want), I won't document it any further.
|
||||
import re
|
||||
import operator
|
||||
|
||||
from _compatibility import use_metaclass, reduce, property
|
||||
import settings
|
||||
import parsing
|
||||
import parsing_representation as pr
|
||||
import cache
|
||||
from jedi._compatibility import use_metaclass, reduce, property
|
||||
from jedi import settings
|
||||
from jedi import parsing
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import cache
|
||||
|
||||
|
||||
class Module(pr.Simple, pr.Module):
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import copy
|
||||
|
||||
import parsing_representation as pr
|
||||
from jedi import parsing_representation as pr
|
||||
|
||||
|
||||
def fast_parent_copy(obj):
|
||||
|
||||
@@ -20,13 +20,13 @@ import pkgutil
|
||||
import imp
|
||||
import sys
|
||||
|
||||
from jedi import modules
|
||||
from jedi import debug
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import itertools
|
||||
from jedi import cache
|
||||
import builtin
|
||||
import modules
|
||||
import debug
|
||||
import parsing_representation as pr
|
||||
import evaluate
|
||||
import itertools
|
||||
import cache
|
||||
|
||||
# for debugging purposes only
|
||||
imports_processed = 0
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import pydoc
|
||||
import keyword
|
||||
|
||||
from _compatibility import is_py3k
|
||||
import builtin
|
||||
from jedi._compatibility import is_py3k
|
||||
from jedi import builtin
|
||||
|
||||
import pydoc
|
||||
try:
|
||||
from pydoc_data import topics as pydoc_topics
|
||||
except ImportError:
|
||||
|
||||
@@ -22,12 +22,12 @@ import tokenize
|
||||
import sys
|
||||
import os
|
||||
|
||||
import cache
|
||||
import parsing
|
||||
import parsing_representation as pr
|
||||
import fast_parser
|
||||
import debug
|
||||
import settings
|
||||
from jedi import cache
|
||||
from jedi import parsing
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import fast_parser
|
||||
from jedi import debug
|
||||
from jedi import settings
|
||||
|
||||
|
||||
class CachedModule(object):
|
||||
|
||||
@@ -20,9 +20,9 @@ from _compatibility import next, StringIO
|
||||
import tokenize
|
||||
import keyword
|
||||
|
||||
import debug
|
||||
import common
|
||||
import parsing_representation as pr
|
||||
from jedi import debug
|
||||
from jedi import common
|
||||
from jedi import parsing_representation as pr
|
||||
|
||||
|
||||
class ParserError(Exception):
|
||||
|
||||
@@ -39,10 +39,10 @@ import os
|
||||
import re
|
||||
import tokenize
|
||||
|
||||
from _compatibility import next, literal_eval, cleandoc, Python3Method, \
|
||||
from jedi._compatibility import next, literal_eval, cleandoc, Python3Method, \
|
||||
encoding, property, unicode, is_py3k
|
||||
import common
|
||||
import debug
|
||||
from jedi import common
|
||||
from jedi import debug
|
||||
|
||||
|
||||
class Base(object):
|
||||
|
||||
@@ -7,11 +7,11 @@ Next to :mod:`cache` this module also makes |jedi| not thread-safe. Why?
|
||||
``ExecutionRecursionDecorator`` uses class variables to count the function
|
||||
calls.
|
||||
"""
|
||||
import parsing_representation as pr
|
||||
import evaluate_representation as er
|
||||
import debug
|
||||
from jedi import parsing_representation as pr
|
||||
from jedi import evaluate_representation as er
|
||||
from jedi import debug
|
||||
from jedi import settings
|
||||
import builtin
|
||||
import settings
|
||||
|
||||
|
||||
class RecursionDecorator(object):
|
||||
|
||||
@@ -15,10 +15,10 @@ following functions (sometimes bug-prone):
|
||||
|
||||
from __future__ import with_statement
|
||||
|
||||
import modules
|
||||
import difflib
|
||||
import helpers
|
||||
import parsing_representation as pr
|
||||
from jedi import modules
|
||||
from jedi import difflib
|
||||
from jedi import helpers
|
||||
from jedi import parsing_representation as pr
|
||||
|
||||
|
||||
class Refactoring(object):
|
||||
|
||||
Reference in New Issue
Block a user