mirror of
https://github.com/python/cpython.git
synced 2025-07-18 08:45:20 +00:00
bpo-41748: Handles unquoted attributes with commas (GH-24072)
* bpo-41748: Adds tests for unquoted attributes with comma
* bpo-41748: Handles unquoted attributes with comma
* bpo-41748: Addresses review comments
* bpo-41748: Addresses review comments
* Adds more test cases
* Simplifies the regex for handling spaces
* bpo-41748: Moves attributes tests under the right class
* bpo-41748: Addresses review about duplicate attributes
* bpo-41748: Adds NEWS.d entry for this patch
(cherry picked from commit 9eb11a139f
)
Co-authored-by: Karl Dubost <karl+github@la-grange.net>
This commit is contained in:
parent
304f9d2622
commit
0874491bcc
3 changed files with 59 additions and 37 deletions
|
@ -46,7 +46,7 @@ locatestarttagend_tolerant = re.compile(r"""
|
|||
|"[^"]*" # LIT-enclosed value
|
||||
|(?!['"])[^>\s]* # bare value
|
||||
)
|
||||
(?:\s*,)* # possibly followed by a comma
|
||||
\s* # possibly followed by a space
|
||||
)?(?:\s|/(?!>))*
|
||||
)*
|
||||
)?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue