Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

3.11.0b1 regression: re.template removed without a deprecation period #92728

Closed
Assignees
serhiy-storchaka
Labels
@hroncok

Description

@hroncok

Bug report

In Python 3.10, there.template function exists andis not deprecated:

>>>import re>>> re.template('', re.I)re.compile('', re.TEMPLATE|re.IGNORECASE)

In Python 3.11.0b1 this function is gone:

>>>import re>>> re.template('', re.I)Traceback (most recent call last):  File "<stdin>", line 1, in <module>AttributeError: module 're' has no attribute 'template'

This was removed inb09184bf05 without a depreciation period.
Despite being undocumented, projects actually use this function, see e.g.rpm-software-management/dnf#1827

Please restore this function and deprecate it in 3.11 and 3.12 if you want to remove it in 3.13. (That is how I understandPEP 387, sectionMaking Incompatible Changes.)

Your environment

  • CPython versions tested on: 3.11.0b1
  • Operating system and architecture: All

Metadata

Metadata

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions


    [8]ページ先頭

    ©2009-2025 Movatter.jp