All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] test/py: usb: Fix format string for fstype command
@ 2025-02-05 13:04 Andrew Goodbody
  2025-02-05 15:30 ` Marek Vasut
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Andrew Goodbody @ 2025-02-05 13:04 UTC (permalink / raw)
  To: u-boot; +Cc: Andrew Goodbody, Love Kumar, Marek Vasut, Tom Rini

USB tests on ext partitions can fail with the following output

test/py/tests/test_usb.py:245: in test_usb_part
    'fstype usb %d:%d' % i, part_id
E   TypeError: not enough arguments for format string

So add brackets around the format string arguments to prevent the
error.

Fixes: a730947974e3 ("test/py: usb: Distinguish b/w ext2/ext4 partitions")
Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>
---

 test/py/tests/test_usb.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/py/tests/test_usb.py b/test/py/tests/test_usb.py
index e1f203b5cbc..566d73b7c64 100644
--- a/test/py/tests/test_usb.py
+++ b/test/py/tests/test_usb.py
@@ -242,7 +242,7 @@ def test_usb_part(u_boot_console):
                     elif part_type == '83':
                         print('ext(2/4) detected')
                         output = u_boot_console.run_command(
-                            'fstype usb %d:%d' % i, part_id
+                            'fstype usb %d:%d' % (i, part_id)
                         )
                         if 'ext2' in output:
                             part_ext2.append(part_id)
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] test/py: usb: Fix format string for fstype command
  2025-02-05 13:04 [PATCH] test/py: usb: Fix format string for fstype command Andrew Goodbody
@ 2025-02-05 15:30 ` Marek Vasut
  2025-02-06  4:58 ` Love Kumar
  2025-02-10 20:38 ` Tom Rini
  2 siblings, 0 replies; 4+ messages in thread
From: Marek Vasut @ 2025-02-05 15:30 UTC (permalink / raw)
  To: Andrew Goodbody, u-boot; +Cc: Love Kumar, Tom Rini

On 2/5/25 2:04 PM, Andrew Goodbody wrote:
> USB tests on ext partitions can fail with the following output
> 
> test/py/tests/test_usb.py:245: in test_usb_part
>      'fstype usb %d:%d' % i, part_id
> E   TypeError: not enough arguments for format string
> 
> So add brackets around the format string arguments to prevent the
> error.
> 
> Fixes: a730947974e3 ("test/py: usb: Distinguish b/w ext2/ext4 partitions")
> Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>
Reviewed-by: Marek Vasut <marex@denx.de>

Thanks !

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] test/py: usb: Fix format string for fstype command
  2025-02-05 13:04 [PATCH] test/py: usb: Fix format string for fstype command Andrew Goodbody
  2025-02-05 15:30 ` Marek Vasut
@ 2025-02-06  4:58 ` Love Kumar
  2025-02-10 20:38 ` Tom Rini
  2 siblings, 0 replies; 4+ messages in thread
From: Love Kumar @ 2025-02-06  4:58 UTC (permalink / raw)
  To: Andrew Goodbody, u-boot; +Cc: Marek Vasut, Tom Rini



On 05/02/25 6:34 pm, Andrew Goodbody wrote:
> USB tests on ext partitions can fail with the following output
> 
> test/py/tests/test_usb.py:245: in test_usb_part
>      'fstype usb %d:%d' % i, part_id
> E   TypeError: not enough arguments for format string
> 
> So add brackets around the format string arguments to prevent the
> error.
> 
> Fixes: a730947974e3 ("test/py: usb: Distinguish b/w ext2/ext4 partitions")
> Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>

Reviewed-by: Love Kumar <love.kumar@amd.com>

Regards,
Love Kumar

> ---
> 
>   test/py/tests/test_usb.py | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/test/py/tests/test_usb.py b/test/py/tests/test_usb.py
> index e1f203b5cbc..566d73b7c64 100644
> --- a/test/py/tests/test_usb.py
> +++ b/test/py/tests/test_usb.py
> @@ -242,7 +242,7 @@ def test_usb_part(u_boot_console):
>                       elif part_type == '83':
>                           print('ext(2/4) detected')
>                           output = u_boot_console.run_command(
> -                            'fstype usb %d:%d' % i, part_id
> +                            'fstype usb %d:%d' % (i, part_id)
>                           )
>                           if 'ext2' in output:
>                               part_ext2.append(part_id)

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] test/py: usb: Fix format string for fstype command
  2025-02-05 13:04 [PATCH] test/py: usb: Fix format string for fstype command Andrew Goodbody
  2025-02-05 15:30 ` Marek Vasut
  2025-02-06  4:58 ` Love Kumar
@ 2025-02-10 20:38 ` Tom Rini
  2 siblings, 0 replies; 4+ messages in thread
From: Tom Rini @ 2025-02-10 20:38 UTC (permalink / raw)
  To: u-boot, Andrew Goodbody; +Cc: Love Kumar, Marek Vasut

On Wed, 05 Feb 2025 13:04:26 +0000, Andrew Goodbody wrote:

> USB tests on ext partitions can fail with the following output
> 
> test/py/tests/test_usb.py:245: in test_usb_part
>     'fstype usb %d:%d' % i, part_id
> E   TypeError: not enough arguments for format string
> 
> So add brackets around the format string arguments to prevent the
> error.
> 
> [...]

Applied to u-boot/master, thanks!

-- 
Tom



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2025-02-10 20:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-05 13:04 [PATCH] test/py: usb: Fix format string for fstype command Andrew Goodbody
2025-02-05 15:30 ` Marek Vasut
2025-02-06  4:58 ` Love Kumar
2025-02-10 20:38 ` Tom Rini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.