Re: [PATCH] perf python: Fix arm-cs-trace-disasm type error

From: Arnaldo Carvalho de Melo

Date: Mon Sep 28 2026 - 12:29:38 EST


On Mon, Sep 28, 2026 at 02:52:04PM +0100, James Clark wrote:
> On 28/09/2026 14:46, Leo Yan wrote:
> > On Mon, Sep 28, 2026 at 01:58:09PM +0100, James Clark wrote:
> > > The perf sample dso_bid getter returns a string or None, matching its
> > > This fixes the following build error:
> > > python/arm-cs-trace-disasm.py:266: error: Item "None" of "str | None" has no attribute "decode" [union-attr]
> > > Fixes: 279b402e5143 ("perf python: Port arm-cs-trace-disasm to perf module")
> > > Assisted-by: Codex:GPT-6-Astra
> > > Signed-off-by: James Clark <james.clark@xxxxxxxxxx>

> > Thanks for the fix:
> > Reviewed-by: Leo Yan <leo.yan@xxxxxxx>

> > Just curious, have you run this script and compare the result with old
> > one? Seems to me, the build pass is insufficient, we should run a small
> > test to ensure the result to keep same.

> Yep the test still passes. I assume the "if isinstance(sample.dso_bid,
> bytes)" part was just dead code.

Thanks, applied to perf-tools-next, for v7.4.

- Arnaldo