Skip to content

Conversation

@Sovietaced
Copy link
Member

@Sovietaced Sovietaced commented Jun 10, 2025

Tracking issue

Fixes flyteorg/flyte#6463

Why are the changes needed?

The pod_spec was not included in the pod template when not using fast registration. This would lead to bad task specification errors on the backend since there would be no pod spec but a primary container name was configured.

Although this comes from our custom Armada plugin, the plugin is just using common pod_helpers code.

RuntimeExecutionError: max number of system retry attempts [31/30] exhausted. Last known status message: failed at Node[n0-n0]. RuntimeExecutionError: failed during plugin execution, caused by: failed to execute handle for plugin [armada]: generating job request: [BadTaskSpecification] invalid TaskSpecification, primary container [primary] not defined

After debugging I found that this was logged from propeller pod_helpers.go code.

podTemplate=metadata:{} pod_spec:{} primary_container_name:"primary"

What changes were proposed in this pull request?

Updates the translation code to render the pod template pod spec unconditionally.

How was this patch tested?

Tested in a production environment.

Setup process

Screenshots

Check all the applicable boxes

  • I updated the documentation accordingly.
  • All new and existing tests passed.
  • All commits are signed-off.

Summary by Bito

This pull request resolves an issue with the pod template override and the pod specification missing during non-fast registration, ensuring the pod spec is rendered unconditionally and enhancing task execution reliability. The changes were validated in a production environment.

Signed-off-by: Jason Parraga <[email protected]>
@codecov
Copy link

codecov bot commented Jun 11, 2025

Codecov Report

Attention: Patch coverage is 33.33333% with 2 lines in your changes missing coverage. Please review.

Project coverage is 75.86%. Comparing base (3c6b61d) to head (bd6d232).
Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
flytekit/tools/translator.py 33.33% 1 Missing and 1 partial ⚠️

❗ There is a different number of reports uploaded between BASE (3c6b61d) and HEAD (bd6d232). Click for more details.

HEAD has 30 uploads less than BASE
Flag BASE (3c6b61d) HEAD (bd6d232)
41 11
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3270      +/-   ##
==========================================
- Coverage   83.35%   75.86%   -7.50%     
==========================================
  Files         347      261      -86     
  Lines       28791    24574    -4217     
  Branches     2960     2962       +2     
==========================================
- Hits        23999    18643    -5356     
- Misses       3956     5106    +1150     
+ Partials      836      825      -11     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Signed-off-by: Jason Parraga <[email protected]>
Copy link
Member

@fg91 fg91 left a comment

Choose a reason for hiding this comment

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

Thanks for fixing, LG 🙏

@samhita-alla samhita-alla merged commit 6a0127c into flyteorg:master Jun 25, 2025
113 of 115 checks passed
Atharva1723 pushed a commit to Atharva1723/flytekit that referenced this pull request Oct 5, 2025
…3270)

* Fix issue where pod template override pod spec was conditionally included

Signed-off-by: Jason Parraga <[email protected]>

* Add unit test

Signed-off-by: Jason Parraga <[email protected]>

* Make unit test parameterized

Signed-off-by: Jason Parraga <[email protected]>

---------

Signed-off-by: Jason Parraga <[email protected]>
Signed-off-by: Atharva <[email protected]>
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.

[BUG] Flytekit > 1.15, new feature of .with_overrides(pod_template) fails to override the pod_template

4 participants