You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This happens inside the SplitByKnownRegistries(unparsed_name, prefixes) function, iff the registry name and the full image name path (to be split into the registry + image name) are the same.
I've reproduced this locally, and understand why this is happening. Previously (before the backfill manifests were merged, this has never happened because we've never had to read images that have an unparsed_name that matches a prefix.
Let's take an example. Currently the us.gcr.io/k8s-artifacts-prod/kube-state-metrics repo has some images in it as a result of the backfill. However, there is also a promoter manifest that names us.gcr.io/k8s-artifacts-prod/kube-state-metrics as a destination repository. Normally, new images under this repository would end up as us.gcr.io/k8s-artifacts-prod/kube-state-metrics/<NEW_IMAGE>. And so normally, this would end up calling SplitByKnownRegistries with us.gcr.io/k8s-artifacts-prod/kube-state-metrics/<NEW_IMAGE> as the unparsed_name and us.gcr.io/k8s-artifacts-prod/kube-state-metrics as one of the prefixes to parse with.
However, ever since the partial backfilling that happened yesterday, there are now images that rest in this same path --- as of the time of this writing, for example, this image:
And so when we read the path us.gcr.io/k8s-artifacts-prod/kube-state-metrics today, we end up calling SplitByKnownRegistries with this name that matches one of the prefixes with the same name, us.gcr.io/k8s-artifacts-prod/kube-state-metrics. When kubernetes/k8s.io#623 was initially merged, we did not see the same error because no root-level images had been populated yet. We saw the error today in https://prow.k8s.io/view/gcs/kubernetes-jenkins/logs/ci-k8sio-cip/1235320791898263552 for the first time because some images like us.gcr.io/k8s-artifacts-prod/kube-state-metrics:v1.4.0 were created due to the partial backfill.
The fix should be simple --- if the image name matches a known prefix, just take everything after the last '/' character.
Most notably, this brings in a promoter "cip" version that shouldn't
choke on images at the top level of repositories:
kubernetes-sigs/promo-tools#188.
@thockin TL;DR: Allowing images to be pushed to the root directory currently breaks the promoter. Fix on the way...!
Pasted error log from ci-k8sio-cip run from earlier today:
(see https://prow.k8s.io/view/gcs/kubernetes-jenkins/logs/ci-k8sio-cip/1235320791898263552)
This happens inside the
SplitByKnownRegistries(unparsed_name, prefixes)
function, iff the registry name and the full image name path (to be split into the registry + image name) are the same.I've reproduced this locally, and understand why this is happening. Previously (before the backfill manifests were merged, this has never happened because we've never had to read images that have an
unparsed_name
that matches aprefix
.Let's take an example. Currently the us.gcr.io/k8s-artifacts-prod/kube-state-metrics repo has some images in it as a result of the backfill. However, there is also a promoter manifest that names
us.gcr.io/k8s-artifacts-prod/kube-state-metrics
as a destination repository. Normally, new images under this repository would end up asus.gcr.io/k8s-artifacts-prod/kube-state-metrics/<NEW_IMAGE>
. And so normally, this would end up callingSplitByKnownRegistries
withus.gcr.io/k8s-artifacts-prod/kube-state-metrics/<NEW_IMAGE>
as theunparsed_name
andus.gcr.io/k8s-artifacts-prod/kube-state-metrics
as one of the prefixes to parse with.However, ever since the partial backfilling that happened yesterday, there are now images that rest in this same path --- as of the time of this writing, for example, this image:
And so when we read the path
us.gcr.io/k8s-artifacts-prod/kube-state-metrics
today, we end up callingSplitByKnownRegistries
with this name that matches one of the prefixes with the same name,us.gcr.io/k8s-artifacts-prod/kube-state-metrics
. When kubernetes/k8s.io#623 was initially merged, we did not see the same error because no root-level images had been populated yet. We saw the error today in https://prow.k8s.io/view/gcs/kubernetes-jenkins/logs/ci-k8sio-cip/1235320791898263552 for the first time because some images likeus.gcr.io/k8s-artifacts-prod/kube-state-metrics:v1.4.0
were created due to the partial backfill.The fix should be simple --- if the image name matches a known prefix, just take everything after the last '/' character.
Related context:
The text was updated successfully, but these errors were encountered: