Thread (16 messages) 16 messages, 2 authors, 2026-01-07

Re: [PATCH net-next v1 13/13] tools: ynl-gen-c: Fix remaining pylint warnings

From: Donald Hunter <donald.hunter@gmail.com>
Date: 2026-01-07 22:32:24
Also in: linux-doc

On Wed, 7 Jan 2026 at 16:45, Jakub Kicinski [off-list ref] wrote:
On Wed,  7 Jan 2026 12:21:43 +0000 Donald Hunter wrote:
quoted
-                     'return ynl_submsg_failed(yarg, "%s", "%s");' %
-                        (self.name, self['selector']),
-                    f"if ({self.nested_render_name}_parse(&parg, {sel_var}, attr))",
+                     f'return ynl_submsg_failed(yarg, "{self.name}", "{self['selector']}");',
+                     f"if ({self.nested_render_name}_parse(&parg, {sel_var}, attr))",
This one breaks build of tools/ with old Python, unfortunately:

  File "/home/virtme/testing/wt-24/tools/net/ynl/generated/../pyynl/ynl_gen_c.py", line 946
    f'return ynl_submsg_failed(yarg, "{self.name}", "{self['selector']}");',
                                                            ^
SyntaxError: f-string: unmatched '['
Yep, this showed up in the AI review as well. I'll fix it along with
the other AI review issues.

Thanks,
Donald
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help