
This issue trackerhas been migrated toGitHub, and is currentlyread-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.
Created on2017-04-30 05:21 byserhiy.storchaka, last changed2022-04-11 14:58 byadmin. This issue is nowclosed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 1361 | merged | serhiy.storchaka,2017-04-30 05:37 | |
| Messages (3) | |||
|---|---|---|---|
| msg292618 -(view) | Author: Serhiy Storchaka (serhiy.storchaka)*![]() | Date: 2017-04-30 05:21 | |
Currently the result of re.compile() with the re.LOCALE flag depends on the locale at compile time. The locale at matching time should be the same as the locale at compile time, otherwise the matching can work incorrectly. This complicates caching in module global functions and increase the chance of race condition.Proposed patch makes re.compile() not depending on locale. Only the locale at matching time affects the result of matching.This is more comprehensive solution ofissue22410. | |||
| msg292970 -(view) | Author: Serhiy Storchaka (serhiy.storchaka)*![]() | Date: 2017-05-04 09:23 | |
This change can be considered as a bug fix, but I hesitate to apply it to maintained releases because the effect on the performance of case-sensitive locale-depending bytes matching is hardly predicable. Some matches become 5 times faster, others become 1.5 times slower, depending on the cases of the pattern and the matched bytestring. | |||
| msg293044 -(view) | Author: Serhiy Storchaka (serhiy.storchaka)*![]() | Date: 2017-05-05 05:53 | |
New changeset898ff03e1e7925ecde3da66327d3cdc7e07625ba by Serhiy Storchaka in branch 'master':bpo-30215: Make re.compile() locale agnostic. (#1361)https://github.com/python/cpython/commit/898ff03e1e7925ecde3da66327d3cdc7e07625ba | |||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:58:45 | admin | set | github: 74401 |
| 2017-05-05 06:42:44 | serhiy.storchaka | set | status: open -> closed resolution: fixed stage: patch review -> resolved |
| 2017-05-05 05:53:42 | serhiy.storchaka | set | messages: +msg293044 |
| 2017-05-04 09:23:25 | serhiy.storchaka | set | messages: +msg292970 |
| 2017-05-04 05:51:55 | serhiy.storchaka | set | assignee:serhiy.storchaka |
| 2017-04-30 05:37:20 | serhiy.storchaka | set | pull_requests: +pull_request1471 |
| 2017-04-30 05:21:39 | serhiy.storchaka | create | |