This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author donallen
Recipients
Date 2006-03-12.14:46:30
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Given the attached test.csv file, the following program
loops forever (can't even ^c):

import re

orig = open('test.csv')

file_contents = orig.read()
orig.close()

find_line = re.compile(r'^(".*")?(,(".*")?)*\n')
search_result = find_line.search(file_contents)
print search_result.span()

The corresponding tcl program works correctly:

set orig [open test.csv r]

set file_contents [read $orig]
close $orig

regexp -indices {^(".*")?(,(".*")?)*\n} $file_contents
\ indices
puts "Indices were $indices"

Both tests were run on a TP G41 running Gentoo Linux.

History
Date User Action Args
2007-08-23 14:38:27adminlinkissue1448325 messages
2007-08-23 14:38:27admincreate