近期在看源码时发现了这个问题,百度了半天没有查到,在StackOverflow上找到了,记录一下
类似的代码就像这种,from后面的包前面有一个点
from ._utils import _import_dotted_name
from ._utils_internal import get_file_path, prepare_multiprocessing_environment
from .version import __version__
from ._six import string_classes as _string_classes
https://stackoverflow.com/questions/7279810/what-does-a-in-an-import-statement-in-python-mean
https://stackoverflow.com/questions/22511792/python-from-dotpackage-import-syntax
https://docs.python.org/3/tutorial/modules.html#importing-from-a-package 见6.4.2. Intra-package References
https://docs.python.org/release/2.5.2/ref/import.html#tok-relative_module