| Message ID | 20260405191443.1209948-9-laurent.pinchart@ideasonboard.com |
|---|---|
| State | New |
| Headers | show |
| Series |
|
| Related | show |
Hi Laurent On Sun, Apr 05, 2026 at 10:14:40PM +0300, Laurent Pinchart wrote: > The reuse tool fails to lint the extract-docs.py file because it > considers the 'SPDX-License-Identifier' string in a regex as a malformed > license identifier. Work around the issue by adding parentheses in the > regular expression, which doesn't affect the behaviour of the regex > matching but prevents the reuse tool from seeing the line. smart move > > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com> > --- > utils/codegen/ipc/extract-docs.py | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/utils/codegen/ipc/extract-docs.py b/utils/codegen/ipc/extract-docs.py > index 61f44caef52a..c51c4ab01a81 100755 > --- a/utils/codegen/ipc/extract-docs.py > +++ b/utils/codegen/ipc/extract-docs.py > @@ -12,7 +12,7 @@ import sys > > regex_block_start = re.compile(r'^/\*\*$') > regex_block_end = re.compile(r'^ \*/$') > -regex_spdx = re.compile(r'^/\* SPDX-License-Identifier: .* \*/$') > +regex_spdx = re.compile(r'^/\* (SPDX)-License-Identifier: .* \*/$') > > > def main(argv): > -- > Regards, > > Laurent Pinchart >
2026. 04. 05. 21:14 keltezéssel, Laurent Pinchart írta: > The reuse tool fails to lint the extract-docs.py file because it > considers the 'SPDX-License-Identifier' string in a regex as a malformed > license identifier. Work around the issue by adding parentheses in the > regular expression, which doesn't affect the behaviour of the regex > matching but prevents the reuse tool from seeing the line. > > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> > --- This is for sure a hack... Reviewed-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com> > utils/codegen/ipc/extract-docs.py | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/utils/codegen/ipc/extract-docs.py b/utils/codegen/ipc/extract-docs.py > index 61f44caef52a..c51c4ab01a81 100755 > --- a/utils/codegen/ipc/extract-docs.py > +++ b/utils/codegen/ipc/extract-docs.py > @@ -12,7 +12,7 @@ import sys > > regex_block_start = re.compile(r'^/\*\*$') > regex_block_end = re.compile(r'^ \*/$') > -regex_spdx = re.compile(r'^/\* SPDX-License-Identifier: .* \*/$') > +regex_spdx = re.compile(r'^/\* (SPDX)-License-Identifier: .* \*/$') > > > def main(argv):
diff --git a/utils/codegen/ipc/extract-docs.py b/utils/codegen/ipc/extract-docs.py index 61f44caef52a..c51c4ab01a81 100755 --- a/utils/codegen/ipc/extract-docs.py +++ b/utils/codegen/ipc/extract-docs.py @@ -12,7 +12,7 @@ import sys regex_block_start = re.compile(r'^/\*\*$') regex_block_end = re.compile(r'^ \*/$') -regex_spdx = re.compile(r'^/\* SPDX-License-Identifier: .* \*/$') +regex_spdx = re.compile(r'^/\* (SPDX)-License-Identifier: .* \*/$') def main(argv):
The reuse tool fails to lint the extract-docs.py file because it considers the 'SPDX-License-Identifier' string in a regex as a malformed license identifier. Work around the issue by adding parentheses in the regular expression, which doesn't affect the behaviour of the regex matching but prevents the reuse tool from seeing the line. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> --- utils/codegen/ipc/extract-docs.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)