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 Rick Otten
Recipients Mark.Shannon, Rick Otten, ezio.melotti, mrabarnett
Date 2015-02-27.00:36:49
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1424997409.44.0.506210201553.issue23532@psf.upfronthosting.co.za>
In-reply-to
Content
Can the documentation be updated to make this more clear?

I see now where the clause "As the target string is scanned, ..." is describing what you have listed here.

I and a coworker both read the description several times and missed that.  I thought it first tried "incorporated" against the whole string, then tried " inc" against the whole string, etc...  When actually it was trying each, "incorporated" and " inc" and the others against the first position of the string.  And then again for the second position.

Since I want to force the order against the whole string before trying the next one for my particular use case, I'll do a series of re.subs instead of trying to do them all in one.  It makes sense now and is easy to fix.

Thanks for looking at it and explaining what is happening more clearly.  It was really not obvious.  I tried at least 100 variations and wasn't seeing the pattern.
History
Date User Action Args
2015-02-27 00:36:49Rick Ottensetrecipients: + Rick Otten, ezio.melotti, mrabarnett, Mark.Shannon
2015-02-27 00:36:49Rick Ottensetmessageid: <1424997409.44.0.506210201553.issue23532@psf.upfronthosting.co.za>
2015-02-27 00:36:49Rick Ottenlinkissue23532 messages
2015-02-27 00:36:49Rick Ottencreate