From f7bc471f5646d53666af347ed77e652dc2f3f956 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Meusel?= Date: Fri, 1 Nov 2024 14:51:57 +0100 Subject: [PATCH] Take 6 --- .github/workflows/ci.yml | 2 +- .github/workflows/nightly.yml | 2 +- src/scripts/repo_config.py | 9 +++++++-- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6e72db945e0..edbdb942a67 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -203,7 +203,7 @@ jobs: - name: Fetch BoringSSL fork for BoGo tests uses: actions/checkout@v4 with: - repository: ${{ env.BORINGSSL_FORK }} + repository: ${{ env.BORINGSSL_REPO }} ref: ${{ env.BORINGSSL_BRANCH }} path: ./boringssl if: matrix.target == 'coverage' || matrix.target == 'sanitizer' diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 81343178bd5..64c346ff5d8 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -50,7 +50,7 @@ jobs: - name: Fetch BoringSSL fork for BoGo tests uses: actions/checkout@v4 with: - repository: ${{ env.BORINGSSL_FORK }} + repository: ${{ env.BORINGSSL_REPO }} ref: ${{ env.BORINGSSL_BRANCH }} path: ./boringssl diff --git a/src/scripts/repo_config.py b/src/scripts/repo_config.py index 1615e3e038a..a1bfaf2d6ab 100644 --- a/src/scripts/repo_config.py +++ b/src/scripts/repo_config.py @@ -44,7 +44,7 @@ def list_vars(cfg: RepoConfig, *_): def get_var(cfg: RepoConfig, args): if args.var not in cfg: print(f'Variable "{args.var}" not found in the configuration file.', file=sys.stderr) - return 1 + raise KeyError() print(cfg[args.var]) def print_config_file_path(cfg, *_): @@ -67,7 +67,12 @@ def print_config_file_path(cfg, *_): parser_file.set_defaults(dispatch=print_config_file_path) args = parser.parse_args() - return args.dispatch(RepoConfig(), args) + try: + args.dispatch(RepoConfig(), args) + except Exception: + return 1 + + return 0 if __name__ == '__main__': sys.exit(main())