From: "Paul Barker" <paul@pbarker.dev>
To: "Stefano Tondo" <stondo@gmail.com>,
<bitbake-devel@lists.openembedded.org>
Cc: "Joshua Watt" <JPEWhacker@gmail.com>,
"Alexander Kanavin" <alex.kanavin@gmail.com>,
"Stefan Herbrechtsmeier" <stefan.herbrechtsmeier@weidmueller.com>
Subject: Re: [PATCH 0/2] fetch: package identity of crate, gomod and npm URLs
Date: Thu, 19 Nov 2026 09:50:54 +0000 [thread overview]
Message-ID: <DMZ3ERL47CEB.3KE9TOG6YIZPD@pbarker.dev> (raw)
In-Reply-To: <20261118092831.201831-1-stondo@gmail.com>
On Wed Nov 18, 2026 at 9:28 AM GMT, Stefano Tondo wrote:
> Hi,
>
> This series adds the fetcher API from the RFC "spdx30: name, version
> and purl for dependency downloads" [1]. Richard asked for a fetcher
> API that returns structured data with the purl, so that OE-Core does
> not read fetcher internals.
>
> Patch 1 adds FetchMethod.package_identity(). It returns the name, the
> version and the purl of the downloaded package, or None. It uses only
> the URL and the datastore, so it works before the fetch and without
> network access.
>
> Patch 2 implements it for the crate, gomod, gomodgit and npm fetchers,
> with unit tests.
>
> The RFC also covered the downloads that gitsm and npmsw add by
> themselves. That part is not in this series. Richard and Alexander
> prefer to list those downloads in SRC_URI. I will send that change
> for npm in a separate series.
>
> An OE-Core series that uses the API follows on the OE-Core list.
>
> [1] https://lore.kernel.org/openembedded-core/20261105122145.543282-1-stondo@gmail.com/
Hi Stefano,
I can't speak for Richard but to me this looks like it's moving in the
right direction.
As the OE-Core changes rely on package_identity() returning a dict with
name, version and purl, I think we should instead make the data
structure more explicit and enforcible.
Perhaps a dataclass in bb.fetch, then package_identity() can return an
instance of this dataclass?
Something like:
@dataclass
class PackageIdentity:
name: str
version: str
purl: str
Best regards,
--
Paul Barker
prev parent reply other threads:[~2026-11-19 9:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-18 9:28 [PATCH 0/2] fetch: package identity of crate, gomod and npm URLs Stefano Tondo
2026-11-18 9:28 ` [PATCH 1/2] fetch: Add package_identity() to the fetchers Stefano Tondo
2026-11-18 9:28 ` [PATCH 2/2] fetch: Return the package identity of crate, gomod and npm URLs Stefano Tondo
2026-11-19 9:50 ` Paul Barker [this message]
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=DMZ3ERL47CEB.3KE9TOG6YIZPD@pbarker.dev \
--to=paul@pbarker.dev \
--cc=JPEWhacker@gmail.com \
--cc=alex.kanavin@gmail.com \
--cc=bitbake-devel@lists.openembedded.org \
--cc=stefan.herbrechtsmeier@weidmueller.com \
--cc=stondo@gmail.com \
/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.