1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-11-02 08:52:45 +01:00

Use raw string for regex patterns in python scripts

Related issue:
https://github.com/uBlockOrigin/uBlock-issues/issues/3229
This commit is contained in:
Raymond Hill 2024-05-05 11:47:31 -04:00
parent 4d8ee35ef7
commit 923452b788
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2
2 changed files with 2 additions and 2 deletions

View File

@ -23,7 +23,7 @@ with open(manifest_out_file) as f:
manifest_out['version'] = version
# Development build? If so, modify name accordingly.
match = re.search('^\d+\.\d+\.\d+\.\d+$', version)
match = re.search(r'^\d+\.\d+\.\d+\.\d+$', version)
if match:
manifest_out['name'] += ' development build'
manifest_out['short_name'] += ' dev build'

View File

@ -21,7 +21,7 @@ with open(firefox_manifest_file) as f2:
firefox_manifest = json.load(f2)
if 'sidebar_action' in firefox_manifest:
match = re.search('^(\d+\.\d+\.\d+)(\.\d+)$', version)
match = re.search(r'^(\d+\.\d+\.\d+)(\.\d+)$', version)
if not match:
# https://bugzilla.mozilla.org/show_bug.cgi?id=1459007
# By design Firefox opens the sidebar with new installation of