Skip to content

Commit ea43050

Browse files
committed
boards.txt.py - use keywords for re.sub count=... and flags=...
https://docs.python.org/3/library/re.html#re.sub > Deprecated since version 3.13: > Passing count and flags as positional arguments is deprecated. > In future Python versions they will be keyword-only parameters.
1 parent 8e2094e commit ea43050

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/boards.txt.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1877,7 +1877,7 @@ def package ():
18771877
substitution += ',\n'.join(board_items)
18781878
substitution += '\n ],'
18791879

1880-
newfilestr = re.sub(r'"boards":[^\]]*\],', substitution, filestr, re.MULTILINE)
1880+
newfilestr = re.sub(r'"boards":[^\]]*\],', substitution, count=filestr, flags=re.MULTILINE)
18811881

18821882
# To get consistent indent/formatting read the JSON and write it out programmatically
18831883
if packagegen:

0 commit comments

Comments
 (0)