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

offline-update: Add wave target pull support #367

Merged
merged 1 commit into from
Feb 7, 2024

Conversation

mike-sul
Copy link
Contributor

@mike-sul mike-sul commented Feb 5, 2024

  • Add ability to download wave's TUF metadata and its target content to the offline update bundle.

  • Correct checking whether the production target exists for a given tag

Copy link
Member

@vkhoroz vkhoroz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Functionally it seems sane to me.

I only have comments to make the implementation easier to understand and/or shorter.

subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
Copy link
Member

@doanac doanac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see you are moving towards doing error messages with a lowercase first word. eg:

errors.New("this is an error")

This makes the Golang linters happier, but its not how we've traditionally done our other stuff.

I think this is probably fine - we need to stop the bleeding, I suppose. But lets make a conscious decision that this is what we want to do.

Everything else seems pretty good - I'll leave it to @vkhoroz to look close at the new logic

subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
subcommands/targets/offline-update.go Show resolved Hide resolved
Copy link
Member

@vkhoroz vkhoroz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

I only have opinions on some messages.
Functionally-wise this is a sound implementation.

Good job!

subcommands/targets/offline-update.go Outdated Show resolved Hide resolved
@mike-sul mike-sul force-pushed the offline-update-improvement branch 2 times, most recently from 143871c to 25b6b49 Compare February 6, 2024 16:35
@mike-sul
Copy link
Contributor Author

mike-sul commented Feb 6, 2024

Squashed all "fixup" commits into the single commit.

Copy link
Member

@vkhoroz vkhoroz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Looks clean.

- Add ability to download wave's TUF metadata and its target content
  to the offline update bundle.

- Correct checking whether the production target exists for a given tag

Signed-off-by: Mike Sul <[email protected]>
@mike-sul mike-sul merged commit b900e29 into main Feb 7, 2024
3 checks passed
@mike-sul mike-sul deleted the offline-update-improvement branch February 7, 2024 10:11
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.

4 participants