Hi team, got a error when I pyflyte register a wor...
# ask-the-community
g
Hi team, got a error when I pyflyte register a workflow. cmd:
Copy code
PYTHONPATH=/pay/src/zoolander pyflyte register src/python/flyte/ml_exploration/dynamic_resource_allocation_example -p ml-exploration -d adhoc -i "<http://containers.global.qa.stripe.io/stripe-qa/flyte/flyte-workflow-minimal-images-2@sha256:1f5b27f07f2ee6c68cb480562dad950184c9bcac590c4f6b2fa220c9173e4f3b|containers.global.qa.stripe.io/stripe-qa/flyte/flyte-workflow-minimal-images-2@sha256:1f5b27f07f2ee6c68cb480562dad950184c9bcac590c4f6b2fa220c9173e4f3b>" -v gilbert3-123456 --deref-symlinks
This is a valid image, but it got the error:
Copy code
AssertionError: Incorrectly formatted image <http://containers.global.qa.stripe.io/stripe-qa/flyte/flyte-workflow-minimal-images-2@sha256:1f5b27f07f2ee6c68cb480562dad950184c9bcac590c4f6b2fa220c9173e4f3b|containers.global.qa.stripe.io/stripe-qa/flyte/flyte-workflow-minimal-images-2@sha256:1f5b27f07f2ee6c68cb480562dad950184c9bcac590c4f6b2fa220c9173e4f3b>, missing tag value
Can someone know how to resolve this?
y
kill the sha?
i think flytekit’s not processing the sha correctly… partly because there’s no check on the backend.
g
We cannot tag the image when we build the image due to some internal constraint. We can only get the image by the image_digest (sha256)
@Ketan (kumare3) Could you take a look pls?
y
so the request is that you’d like the image that you specify to be sha based rather than tag?
g
Yeah, exactly
y
and you’d like it to be persisted like that across the board - like in the task definition…
g
It's weird that we don't support image digest
y
and when it’s launched on k8s
so the pod when it’s run, it’d use the sha?
g
and you’d like it to be persisted like that across the board - like in the task definition…
Any risk by doing so? fwiw container is just a uri, it doesn't really matter how it looks like right?
y
no concern from flyte’s perspective… it’s just a string. so it’s just the parsing logic we do here and there.
as long as fetching images by sha is a supported part of the oci api
g
I see! I just don't understand why I cannot pass image sha🥲
Can we support that?
y
if it’s supported by k8s/oci it’s something we should support.
mind cutting a ticket for this?
we will investigate and get back to you on there.
g
mind cutting a ticket for this?
Sure, how can I cut it?
g
Thanks Yee!
Hi @Yee! May I know any update on this? I have to re-adjust our project plan based on this release date.
y
sorry i haven’t even thought about this yet.
could you try this?
basically we just need to verify 1) k8s works with images specified like this - just spin up a pod with this as the image and 2) flyte works - i think we just need to adjust the image parsing part in flytekit, the rest of the system treats it like a string.
cc @Eduardo Apolinario (eapolinario) - can you think of any reason why this won’t work?
g
I believe the image parsing part in flytekit block this format of image_uri
could you try this?
hmm, try what?
y
making the change in flytekit 🙂
?
g
Oh you mean I make a PR for that?
y
yeah would you be up for it?
g
I am not sure I got the enough knowledge to do this