Skip to content

fix: lookup image id with tag rather than name during tryImport #5165

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

Conversation

wheelsandmetal
Copy link
Contributor

@wheelsandmetal wheelsandmetal commented Dec 17, 2020

Fixes: #5162

Description

Lookup the imageID with the tag rather than the image name.

My guess at what is happening is that there are 2 images with the same name but different tags and thus it can't produce a singular image ID. In may case the 2 images where:

In this case the tag also includes the image name so I don't think there is any chance that 2 images match again.

@codecov
Copy link

codecov bot commented Dec 17, 2020

Codecov Report

Merging #5165 (ab16982) into master (e9c9bdb) will decrease coverage by 0.48%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #5165      +/-   ##
==========================================
- Coverage   72.33%   71.85%   -0.49%     
==========================================
  Files         384      384              
  Lines       13621    13729     +108     
==========================================
+ Hits         9853     9865      +12     
- Misses       3048     3138      +90     
- Partials      720      726       +6     
Impacted Files Coverage Δ
pkg/skaffold/build/cache/lookup.go 87.87% <100.00%> (ø)
pkg/skaffold/instrumentation/meter.go 23.02% <0.00%> (-41.50%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e9c9bdb...ab16982. Read the comment docs.

@wheelsandmetal wheelsandmetal force-pushed the lookup-imageID-with-tag branch from 13c2974 to ab16982 Compare December 18, 2020 13:07
Copy link
Member

@briandealwis briandealwis left a comment

Choose a reason for hiding this comment

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

I can reproduce the failure and your change works for me. Thanks for the fix!

@briandealwis briandealwis added the kokoro:run runs the kokoro jobs on a PR label Dec 21, 2020
@kokoro-team kokoro-team removed the kokoro:run runs the kokoro jobs on a PR label Dec 21, 2020
@briandealwis briandealwis merged commit a6f3bd7 into GoogleContainerTools:master Dec 21, 2020
@wheelsandmetal wheelsandmetal deleted the lookup-imageID-with-tag branch January 4, 2021 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

tryImportMissing always building new image, despite pull suceeding
3 participants