Skip to content

Commit

Permalink
fix breaking changes CICD
Browse files Browse the repository at this point in the history
  • Loading branch information
guewa committed Jan 17, 2025
1 parent 81c7b85 commit 2d99340
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions .ci/update_release.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,20 @@
# SPDX-License-Identifier: Apache-2.0

import pathlib
from ci.util import ctx
from ci.util import (
check_env,
ctx,
)
import ccc.github

import os

from github.util import GitHubRepositoryHelper

VERSION_FILE_NAME = 'VERSION'

repo_owner_and_name = util.check_env('SOURCE_GITHUB_REPO_OWNER_AND_NAME')
repo_dir = util.check_env('MAIN_REPO_DIR')
repo_owner_and_name = check_env('SOURCE_GITHUB_REPO_OWNER_AND_NAME')
repo_dir = check_env('MAIN_REPO_DIR')

repo_owner, repo_name = repo_owner_and_name.split('/')

Expand All @@ -25,11 +30,12 @@

cfg_factory = ctx().cfg_factory()
github_cfg = cfg_factory.github('github_com')
github_api = ccc.github.github_api(github_cfg)

github_repo_helper = GitHubRepositoryHelper(
owner=repo_owner,
name=repo_name,
github_cfg=github_cfg,
github_api=github_api,
)

gh_release = github_repo_helper.repository.release_from_tag(version_file_contents)
Expand All @@ -40,7 +46,7 @@
except KeyError:
print("No integration test output path found. Output will not be added to release")
else:
integration_test_path = util.check_env('INTEGRATION_TEST_PATH')
integration_test_path = check_env('INTEGRATION_TEST_PATH')
integration_test_path = pathlib.Path(integration_test_path).resolve()
integration_test_path = integration_test_path / "integration_test.log"
gh_release.upload_asset(
Expand Down

0 comments on commit 2d99340

Please sign in to comment.