1111 logger ,
1212)
1313from src .exceptions import GithubPRFailedException
14- from src .github_api_client import GithubAPIClient , RHDHPluginUpdaterConfig
14+ from src .github_api_client import GithubAPIClient
1515from src .loader import RHDHPluginsConfigLoader
16- from src .types import GithubPullRequestStrategy , RHDHPluginUpdate
16+ from src .types import (
17+ GithubPullRequestStrategy ,
18+ RHDHPluginUpdate ,
19+ RHDHPluginUpdaterConfig ,
20+ )
1721from src .updater import RHDHPluginConfigUpdater
1822from src .utils import rhdh_plugin_needs_update
1923
@@ -31,6 +35,9 @@ def main():
3135 rhdh_config_loader = RHDHPluginsConfigLoader ()
3236 rhdh_config_updater = RHDHPluginConfigUpdater ()
3337 rhdh_plugins = rhdh_config_loader .load_rhdh_plugins ()
38+ trimmed_file_path = DYNAMIC_PLUGINS_CONFIG_YAML_FILE_PATH .replace (
39+ RHDHPluginUpdaterConfig .GH_RUNNER_PREFIX , ""
40+ )
3441
3542 logger .info (f"found { len (rhdh_plugins )} RHDH plugins to check for updates" )
3643
@@ -82,7 +89,7 @@ def main():
8289
8390 pr_url = gh_api_client .create_pull_request (
8491 repo_full_name = GITHUB_REPOSITORY ,
85- file_path = DYNAMIC_PLUGINS_CONFIG_YAML_FILE_PATH ,
92+ file_path = trimmed_file_path ,
8693 new_content = updated_yaml ,
8794 branch_name = RHDHPluginUpdaterConfig .GH_PR_BRANCH_NAME_BASE .format (
8895 plugin_name = plugin .plugin_name , latest_version = latest_version
@@ -125,7 +132,7 @@ def main():
125132
126133 pr_url = gh_api_client .create_pull_request (
127134 repo_full_name = GITHUB_REPOSITORY ,
128- file_path = DYNAMIC_PLUGINS_CONFIG_YAML_FILE_PATH ,
135+ file_path = trimmed_file_path ,
129136 new_content = updated_yaml ,
130137 branch_name = RHDHPluginUpdaterConfig .GH_BULK_PR_BRANCH_NAME_BASE ,
131138 pr_title = RHDHPluginUpdaterConfig .GH_BULK_PR_TITLE_BASE .format (
0 commit comments