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

From: Jakub Kicinski <[email-masked]>
Date: Wed, 7 Jan 2026 08:45:34 -0800

On Wed,  7 Jan 2026 12:21:43 +0000 Donald Hunter wrote:
> -                     '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 '['
make[2]: *** [Makefile:48: psp-user.c] Error 1
make[1]: *** [Makefile:28: generated] Error 2
make: *** [../../net/ynl.mk:31: /home/virtme/testing/wt-24/tools/testing/selftests/drivers/net/libynl.a] Error 2
-- 
pw-bot: cr