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


Groups > comp.lang.python > #60387

Re: Importing by file name

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!goblin3!goblin2!goblin.stu.neva.ru!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.000
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'from:addr:yahoo.co.uk': 0.04; '(except': 0.07; 'subject:file': 0.07; 'lawrence': 0.09; 'pep': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'tismer': 0.09; 'python': 0.11; '3.3,': 0.16; 'behaviour.': 0.16; 'it),': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'rewritten': 0.16; 'url:peps': 0.16; 'url:whatsnew': 0.16; 'language': 0.16; 'wrote:': 0.18; 'bit': 0.19; 'mechanism': 0.19; 'written': 0.21; 'programming': 0.22; 'import': 0.22; 'header :User-Agent:1': 0.23; 'url:dev': 0.24; 'second': 0.26; 'header:X -Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; 'url:bugs': 0.29; '(although': 0.31; "d'aprano": 0.31; 'steven': 0.31; 'url:python': 0.33; 'bugs': 0.33; 'but': 0.35; 'there': 0.35; 'url:org': 0.36; 'list': 0.37; 'christian': 0.38; 'to:addr:python- list': 0.38; 'rather': 0.38; 'does': 0.39; 'moving': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'most': 0.60; 'full': 0.61; 'url:3': 0.61; 'world.': 0.61; 'nobody': 0.68; '3.4': 0.84; 'received:89': 0.85
X-Injected-Via-Gmane http://gmane.org/
To python-list@python.org
From Mark Lawrence <breamoreboy@yahoo.co.uk>
Subject Re: Importing by file name
Date Sun, 24 Nov 2013 16:30:27 +0000
References <CAPTjJmqhiyT9zVHFRyKH0UwhdhFgZxA1rcbarChePMyfK7dDTA@mail.gmail.com> <CALwzidmqKkpuugv2zvu-8RpoVZF899G2Hpdmd_kVn8a33WMWFw@mail.gmail.com> <mailman.3119.1385280468.18130.python-list@python.org> <52920a19$0$29993$c3e8da3$5496439d@news.astraweb.com>
Mime-Version 1.0
Content-Type text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding 7bit
X-Gmane-NNTP-Posting-Host host-89-240-173-71.as13285.net
User-Agent Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.1.1
In-Reply-To <52920a19$0$29993$c3e8da3$5496439d@news.astraweb.com>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.3143.1385310641.18130.python-list@python.org> (permalink)
Lines 23
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1385310641 news.xs4all.nl 15931 [2001:888:2000:d::a6]:44719
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:60387

Show key headers only | View raw


On 24/11/2013 14:15, Steven D'Aprano wrote:
>
> That was the case up to 3.3, but Python 3.4 has the import machinery re-
> written in pure Python (except for a tiny bit of bootstrapping machinery,
> if I understand correctly). I understand that nobody understood the
> import machinery in full (although there were a couple of people who
> understood most of it), and that moving it to Python was a Herculean job.
> If I remember correctly, it uncovered a number of undetected bugs and
> dark corners with unspecified behaviour.
>

The import mechanism was rewritten in 3.3 see 
http://docs.python.org/3/whatsnew/3.3.html#importlib.  PEP 451 also does 
work on the import mechanism http://www.python.org/dev/peps/pep-0451/ 
This is in 3.4, see http://bugs.python.org/issue18864 and a rather long 
list of associated issues.

-- 
Python is the second best programming language in the world.
But the best has yet to be invented.  Christian Tismer

Mark Lawrence

Back to comp.lang.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: Importing by file name Chris Angelico <rosuav@gmail.com> - 2013-11-24 19:07 +1100
  Re: Importing by file name Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-11-24 14:15 +0000
    Re: Importing by file name Chris Angelico <rosuav@gmail.com> - 2013-11-25 01:25 +1100
    Re: Importing by file name Mark Lawrence <breamoreboy@yahoo.co.uk> - 2013-11-24 16:30 +0000

csiph-web