Skip to content

Comments

Add support for parsing OSGi dependencies and .bnd files#4765

Open
pantha704 wants to merge 1 commit intoaboutcode-org:developfrom
pantha704:fix-issue-3295-osgi-bnd
Open

Add support for parsing OSGi dependencies and .bnd files#4765
pantha704 wants to merge 1 commit intoaboutcode-org:developfrom
pantha704:fix-issue-3295-osgi-bnd

Conversation

@pantha704
Copy link

Resolves #3295.

This PR adds support for parsing OSGi bundle metadata and dependencies from MANIFEST.MF and .bnd properties files.

  • Extends the existing jar_manifest.py to parse Import-Package and Require-Bundle headers, properly extracting version data, optional resolution parameters, and runtime scope, and outputting them as DependentPackage objects.
  • Extracts other OSGi fields (like Export-Package, Bundle-Description, Require-Capability, etc.) into the extra_data mapping.
  • Implements OsgiBndHandler within maven.py to handle *.bnd properties files natively using the javaproperties library.
  • Includes comprehensive tests and regenerated data-driven test fixtures to validate OSGi parsing logic and expected payloads.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add/improve support for OSGI bundle metadata from bnd

1 participant