Skip to content

don't rely on version_id magic #233

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

Merged
merged 1 commit into from
Jul 7, 2025
Merged

Conversation

nammn
Copy link
Collaborator

@nammn nammn commented Jul 7, 2025

Summary

This pull request updates the tagging scheme in the inventory.yaml file to replace the version_id parameter with the version parameter for consistency and clarity across all image tags. The changes affect multiple sections of the file, ensuring uniformity in how image tags are generated.

version_id is a evergreen magic env which sonar magically picks up and puts into inventory. Therefore we had those weird tags. This magic is not required anymore - since we pass version on every image creation ourselves:

def get_git_release_tag() -> str:
"""Returns the git tag of the current run on releases, on non-release returns the patch id."""
release_env_var = os.getenv("triggered_by_git_tag")
# that means we are in a release and only return the git_tag; otherwise we want to return the patch_id
# appended to ensure the image created is unique and does not interfere
if release_env_var is not None:
logger.info(f"git tag detected: {release_env_var}")
return release_env_var
patch_id = os.environ.get("version_id", "latest")
logger.info(f"No git tag detected, using patch_id: {patch_id}")
return patch_id
. Additionally, operator was the only leftover where we still used that version_id

Proof of Work

  • passing ci image build

Checklist

  • Have you linked a jira ticket and/or is the ticket in the title?
  • Have you checked whether your jira ticket required DOCSP changes?
  • Have you checked for release_note changes?

Reminder (Please remove this when merging)

  • Please try to Approve or Reject Changes the PR, keep PRs in review as short as possible
  • Our Short Guide for PRs: Link
  • Remember the following Communication Standards - use comment prefixes for clarity:
    • blocking: Must be addressed before approval.
    • follow-up: Can be addressed in a later PR or ticket.
    • q: Clarifying question.
    • nit: Non-blocking suggestions.
    • note: Side-note, non-actionable. Example: Praise
    • --> no prefix is considered a question
@nammn nammn requested a review from a team as a code owner July 7, 2025 09:31
@nammn nammn requested review from anandsyncs and Julien-Ben July 7, 2025 09:31
@nammn nammn merged commit 603bf0f into release-1.2 Jul 7, 2025
8 of 12 checks passed
@nammn nammn deleted the pipeline-fix-rely-version_id branch July 7, 2025 09:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants