All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefano Tondo <stondo@gmail.com>
To: openembedded-core@lists.openembedded.org
Cc: yoann.congal@smile.fr, jpewhacker@gmail.com,
	peter.marko@siemens.com, adrian.freihofer@siemens.com,
	patrick.wicki@siemens.com, stefano.tondo.ext@siemens.com
Subject: [wrynose][PATCH 0/4] spdx30: fix the source download enrichment
Date: Wed, 11 Nov 2026 18:35:33 +0100	[thread overview]
Message-ID: <20261111173537.3653558-1-stondo@gmail.com> (raw)

Hi Yoann,

This series backports three spdx30 fixes from master to wrynose, plus
their tests. Patches 2 to 4 also go to blacksail in a separate series.
Blacksail already has patch 1.

Wrynose has 9f1825e74d ("spdx30: Add Git version and PURL to source
downloads"). It adds the commit hash as version and a purl to the Git
source downloads in the SPDX. That code has three bugs, and master
fixed all of them:

1. spdx30_tasks: Fix duplicated revision in Git PURLs (e31479ddba)

   On wrynose, every Git purl has the revision twice, for example
   pkg:github/fastfloat/fast_float@<rev>@<rev>. That purl is invalid,
   so scanners cannot match it. Master reformatted the file after this
   fix, so I applied it by hand. The change is the same.

2. spdx30: Make source download enrichment part of the task signature
   (e57ec14f8d)

   The enrichment code is in two functions whose names start with an
   underscore. bitbake leaves such functions out of the task
   signature. So do_create_spdx did not track them, or the
   SPDX_GIT_PURL_MAPPINGS variable that they read. After a change,
   bitbake restored the old SPDX from sstate. The fix renames the two
   functions. As a side effect, the do_create_spdx signature of every
   recipe changes once.

3. spdx30: Enrich gitsm source downloads like git ones (1e5146d8f9)

   This one can look like a feature, but I think it is a fix.
   9f1825e74d enriches Git source downloads, but it checks only
   fd.type == "git". gitsm is the Git fetcher with submodule support,
   and it has the same revision. So a recipe that changes from git://
   to gitsm:// loses the version and the purl of its main repository,
   with no warning. The fix is one line.

4. oeqa/selftest: Add tests for source download enrichment
   (3ca309cbd3)

   Two selftests for patches 2 and 3, which fail without them. On
   wrynose, test_git_purl_mappings_rerun_create_spdx also fails
   without patch 1. That is how I found that wrynose does not have it.
   If you take only fixes, you can drop this patch. Patchwork can show
   it as accepted already, because a March commit (9a622a2062) has the
   same subject.

I tested the series with oe-selftest -r spdx.SPDX30Check on wrynose
(bitbake 2.18). All 14 tests pass.

KAZUYOSHI AKIYAMA (秋山 和慶) (1):
  spdx30_tasks: Fix duplicated revision in Git PURLs

Stefano Tondo (3):
  spdx30: Make source download enrichment part of the task signature
  spdx30: Enrich gitsm source downloads like git ones
  oeqa/selftest: Add tests for source download enrichment

 meta/lib/oe/spdx30_tasks.py          | 17 +++++-----
 meta/lib/oeqa/selftest/cases/spdx.py | 47 ++++++++++++++++++++++++++++
 2 files changed, 57 insertions(+), 7 deletions(-)

-- 
2.56.0


             reply	other threads:[~2026-11-11 17:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-11 17:35 Stefano Tondo [this message]
2026-11-11 17:35 ` [wrynose][PATCH 1/4] spdx30_tasks: Fix duplicated revision in Git PURLs Stefano Tondo
2026-11-11 17:35 ` [wrynose][PATCH 2/4] spdx30: Make source download enrichment part of the task signature Stefano Tondo
2026-11-11 17:35 ` [wrynose][PATCH 3/4] spdx30: Enrich gitsm source downloads like git ones Stefano Tondo
2026-11-11 17:35 ` [wrynose][PATCH 4/4] oeqa/selftest: Add tests for source download enrichment Stefano Tondo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261111173537.3653558-1-stondo@gmail.com \
    --to=stondo@gmail.com \
    --cc=adrian.freihofer@siemens.com \
    --cc=jpewhacker@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=patrick.wicki@siemens.com \
    --cc=peter.marko@siemens.com \
    --cc=stefano.tondo.ext@siemens.com \
    --cc=yoann.congal@smile.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.