New submission from Piotr Kuchta: In the 2.7 tutorial, chapter on modules:
http://docs.python.org/2/tutorial/modules.html#more-on-modules I think the last sentence in this paragraph is incorrect: "Modules can import other modules. It is customary but not required to place all import statements at the beginning of a module (or script, for that matter). The imported module names are placed in the importing module’s global symbol table." This is not true: >>> def foo(): import sys ... >>> foo() >>> sys.path Traceback (most recent call last): File "<stdin>", line 1, in <module> NameError: name 'sys' is not defined ---------- assignee: docs@python components: Documentation messages: 183715 nosy: Piotr.Kuchta, docs@python priority: normal severity: normal status: open title: Error in documentation /2/tutorial/modules.html#more-on-modules versions: Python 2.7 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue17383> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com