classification
Title: Patch to add imp.get_codingspec()
Type: enhancement Stage:
Components: Library (Lib) Versions: Python 3.2
process
Status: closed Resolution: out of date
Dependencies: Superseder:
Assigned To: Nosy List: benjamin.peterson, brett.cannon, christian.heimes
Priority: low Keywords: patch

Created on 2008-08-18 21:13 by brett.cannon, last changed 2010-08-09 21:01 by brett.cannon. This issue is now closed.

Files
File name Uploaded Description Edit
reviewed_get_encodingspec.diff brett.cannon, 2008-08-18 21:13
Messages (3)
msg71379 - (view) Author: Brett Cannon (brett.cannon) * (Python committer) Date: 2008-08-18 21:13
Attached is a patch to add imp.get_codingspec(); a function that returns
the encoding of a source file.

The motivation is to remove the import of the re module in linecache to
speed up interpreter startup.
msg71380 - (view) Author: Brett Cannon (brett.cannon) * (Python committer) Date: 2008-08-18 21:14
It should be noted the original patch by Christian had a check for bad
tokenizing. Turns out that if you have that in several tests fail,
including test_modulefinder. This might mean there is a deeper problem
in the parser.
msg113412 - (view) Author: Benjamin Peterson (benjamin.peterson) * (Python committer) Date: 2010-08-09 12:59
We don't need this. We have tokenize.detect_encoding().
History
Date User Action Args
2010-08-09 21:01:28brett.cannonsetstatus: open -> closed
keywords: patch, patch
resolution: out of date
2010-08-09 12:59:39benjamin.petersonsetkeywords: patch, patch
nosy: + benjamin.peterson
messages: + msg113412

2010-08-09 04:29:44terry.reedysetkeywords: patch, patch
versions: + Python 3.2, - Python 3.1
2008-08-18 21:14:48brett.cannonsetkeywords: patch, patch
messages: + msg71380
2008-08-18 21:13:51brett.cannoncreate