Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix implicit version handling of an artifact identity #1026

Merged
merged 4 commits into from
Nov 12, 2024

Conversation

mandelsoft
Copy link
Contributor

@mandelsoft mandelsoft commented Oct 29, 2024

What this PR does / why we need it

The defaulting of the extraIdentity did only work, if there was an identity map already set.

So far the version was implicutly added to the extraIdentity of a CV if the rest is not
unique. In the future the extraIdentity should be explicitly set to be unique. Therefore,
the version was now implicitly added to the extraIdentity. This has two problems:

  • it was only done, if there was already an identity map set,
  • it was always done, when serializing a CD

To be comparable with older signed component versions, such defaulting may only be done
if the content of a component version is changed, otherwise the signature would be brocken.

Which issue(s) this PR fixes

@jakobmoellerdev
Copy link
Contributor

A second fix is included for the creation of an artifact set for an OCI artifact access.
The switch from tag to digest priority resulted in an artifact set not containing all the manifest
meta data. This is fixed by keeping both parts (tag + digest) and extracting the optional
tag for creating the manifest meta data.

Would you mind separating this into

  1. a separate commit
  2. a new PR

I will continue reviewing the existing fix for the implicit version handling

@mandelsoft mandelsoft force-pushed the version branch 2 times, most recently from e723f76 to 6981451 Compare October 31, 2024 10:08
@mandelsoft mandelsoft force-pushed the version branch 4 times, most recently from e1b5515 to 05cbf1b Compare November 7, 2024 17:19
@hilmarf hilmarf added this to the 2024-Q4 milestone Nov 11, 2024
unified handling of modification of elements

ocm hash tests

generate reference doc

revert oci related changes
@mandelsoft mandelsoft closed this Nov 12, 2024
@mandelsoft mandelsoft reopened this Nov 12, 2024
@jakobmoellerdev jakobmoellerdev merged commit 782970c into open-component-model:main Nov 12, 2024
40 checks passed
@mandelsoft mandelsoft deleted the version branch November 12, 2024 14:54
@hilmarf hilmarf linked an issue Nov 14, 2024 that may be closed by this pull request
@hilmarf hilmarf added the kind/bugfix Bug label Nov 28, 2024
jakobmoellerdev added a commit to jakobmoellerdev/ocm that referenced this pull request Dec 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: 🔒Closed
Development

Successfully merging this pull request may close these issues.

Unexpectedly added version property to extraIdentity
3 participants