summaryrefslogtreecommitdiffstats
path: root/bitbake/lib
diff options
context:
space:
mode:
authorBin Lan <bin.lan.cn@windriver.com>2025-01-09 10:00:02 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2025-01-14 09:51:45 +0000
commit33271912bf25a51d86cf07f5d3e2042c04d17245 (patch)
tree035fa2a16a84ad7e4d7337235145d8ad5b71fe5c /bitbake/lib
parent2abb0028ba91291e13fe7c218d87dd7e6f379ace (diff)
downloadpoky-33271912bf25a51d86cf07f5d3e2042c04d17245.tar.gz
bitbake: bb/fetch2/__init__.py: remove a DeprecationWarning in uri_replace()
There is the following warning when executing to bitbake linux-yocto: bitbake/lib/bb/fetch2/__init__.py:464: DeprecationWarning: 'count' is passed as positional argument This is because the 4th parameter of re.sub(pattern, repl, string, count=0, flags=0) is a keyword parameter. We use keyword arguments for parameters that are not positional. (Bitbake rev: 4bd62639f7023eec9f55ad7909fa9250538de936) Signed-off-by: Bin Lan <bin.lan.cn@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib')
-rw-r--r--bitbake/lib/bb/fetch2/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py
index 4dc94e6f2b..de36f06bfc 100644
--- a/bitbake/lib/bb/fetch2/__init__.py
+++ b/bitbake/lib/bb/fetch2/__init__.py
@@ -461,7 +461,7 @@ def uri_replace(ud, uri_find, uri_replace, replacements, d, mirrortarball=None):
461 for k in replacements: 461 for k in replacements:
462 uri_replace_decoded[loc] = uri_replace_decoded[loc].replace(k, replacements[k]) 462 uri_replace_decoded[loc] = uri_replace_decoded[loc].replace(k, replacements[k])
463 #bb.note("%s %s %s" % (regexp, uri_replace_decoded[loc], uri_decoded[loc])) 463 #bb.note("%s %s %s" % (regexp, uri_replace_decoded[loc], uri_decoded[loc]))
464 result_decoded[loc] = re.sub(regexp, uri_replace_decoded[loc], uri_decoded[loc], 1) 464 result_decoded[loc] = re.sub(regexp, uri_replace_decoded[loc], uri_decoded[loc], count=1)
465 if loc == 2: 465 if loc == 2:
466 # Handle path manipulations 466 # Handle path manipulations
467 basename = None 467 basename = None