Brett Cannon added the comment:

I am not convinced this an infinite loop but more of a poor-performing
regex over a large string.

You have three greedy quantifiers in that regex.  That means the first
one is going to consume the entire file, and then you begin back-off
looking for '://'.  Once that is found you consume the rest of the
string again and then back off looking for ':'.  Then the rest of the
string is consumed and then back-off begins for '@' which should fail
since I can't find a single instance of '@'.

But that is a lot of backing off over a large string which has a ton of
partial matches before failure occurs when looking for the '@'.  It
looks like you are trying to match a URL, which means you probably want
something more specific than '.' for those greedy quantifiers.

Closing as invalid.

----------
assignee:  -> brett.cannon
nosy: +brett.cannon
resolution:  -> invalid
status: open -> closed

__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue1217>
__________________________________
_______________________________________________
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to