Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #81954 > unrolled thread

Re: Style question: Importing modules from packages - 'from' vs 'as'

Started byChris Angelico <rosuav@gmail.com>
First post2014-12-05 09:24 +1100
Last post2014-12-05 09:24 +1100
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Style question: Importing modules from packages - 'from' vs 'as' Chris Angelico <rosuav@gmail.com> - 2014-12-05 09:24 +1100

#81954 — Re: Style question: Importing modules from packages - 'from' vs 'as'

FromChris Angelico <rosuav@gmail.com>
Date2014-12-05 09:24 +1100
SubjectRe: Style question: Importing modules from packages - 'from' vs 'as'
Message-ID<mailman.16592.1417731875.18130.python-list@python.org>
On Fri, Dec 5, 2014 at 9:10 AM, Wolfgang Maier
<wolfgang.maier@biologie.uni-freiburg.de> wrote:
> which I read as there has been a stepwise transition between 2.5 and 2.7 so
> that 2.7 now behaves like Python 3 even without the __future__ statement.
> OTOH, I believe you, of course, if you're saying implicit relative imports
> are working just fine in 2.7, but then how to interpret the "In Python 2.7
> the __future__ statement is not needed." above ?

Hmm. To be honest, I'm not sure. The Python 2.7 __future__ module
claims that absolute_import became standard in 3.0, not 2.7, which
seems to conflict with what you're seeing.

ChrisA

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web