Skip to content

Conversation

@bismansahni
Copy link
Contributor

Summary

Fixes issue #712 where container image save command fails with a notFound error when no platform options are specified.

The fix adds a default to use the current platform when --platform, --arch, and --os flags are all unspecified, preventing the platform variable from being nil.

Changes

  • Modified ImageSave.swift to default to Platform.current when no platform options are provided

Test plan

  • Build the project successfully
  • Verify that container image save now works without platform flags
  • Ensure existing behavior with explicit platform flags remains unchanged

Fixes #712

bismansahni and others added 3 commits October 6, 2025 13:14
When saving images without specifying --platform, --arch, or --os flags,
the command now defaults to the current platform instead of failing with
a notFound error.

Fixes apple#712
@katiewasnothere katiewasnothere self-requested a review October 13, 2025 16:10
@bismansahni
Copy link
Contributor Author

Hi @katiewasnothere, can you have a look at this pr :)

@katiewasnothere
Copy link
Contributor

Hi @bismansahni, sorry for the delay and thank you for the contribution!

I know we have an open issue here to push/pull the current platform by default. I see there's a PR for that here, which may be out of date and need to be updated. Based on the comment in that PR, I'm wondering if it would be better for us to do that change and this change at the same time so we can keep the behavior consistent between image pull, push, save, load, etc.

What do you think? I'm open to other thoughts on the approach here

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.

[Request]: Image save command: platform default to current

2 participants