From e05cb208d0e591fef8692c4e15abf9d0750a8959 Mon Sep 17 00:00:00 2001 From: Puneet Dixit <236133619+puneetdixit200@users.noreply.github.com> Date: Tue, 26 May 2026 10:46:19 +0530 Subject: [PATCH 1/2] chore: handle empty TypeScript declaration lint selections Signed-off-by: Puneet Dixit <236133619+puneetdixit200@users.noreply.github.com> --- .github/workflows/lint_random_files.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/lint_random_files.yml b/.github/workflows/lint_random_files.yml index 0f6201bcb3b3..d7587fdaaff1 100644 --- a/.github/workflows/lint_random_files.yml +++ b/.github/workflows/lint_random_files.yml @@ -521,9 +521,11 @@ jobs: if: ( github.event.inputs.javascript != 'false' ) && ( success() || failure() ) run: | set -o pipefail - files=$(echo "${{ steps.random-files.outputs.files }}" | tr ',' '\n' | grep -E '\.d\.ts$' | tr '\n' ' ') + files=$(echo "${{ steps.random-files.outputs.files }}" | tr ',' '\n' | grep -E '\.d\.ts$' | tr '\n' ' ' || true) if [[ -n "${files}" ]]; then make TYPESCRIPT_DECLARATIONS_LINTER=eslint lint-typescript-declarations-files FAST_FAIL=0 FILES="${files}" 2>&1 | tee lint_typescript_declarations_errors.txt + else + echo "No TypeScript declaration files to lint." fi # Create sub-issue for TypeScript declarations lint failures: From 2cfd967131ac044b08b97487c57b3dc8f1cfb0b3 Mon Sep 17 00:00:00 2001 From: Athan Date: Wed, 27 May 2026 15:26:38 -0700 Subject: [PATCH 2/2] Apply suggestions from code review Co-authored-by: Athan Signed-off-by: Athan --- .github/workflows/lint_random_files.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/lint_random_files.yml b/.github/workflows/lint_random_files.yml index d7587fdaaff1..6e1cad3263a0 100644 --- a/.github/workflows/lint_random_files.yml +++ b/.github/workflows/lint_random_files.yml @@ -520,12 +520,9 @@ jobs: id: lint-typescript-declarations if: ( github.event.inputs.javascript != 'false' ) && ( success() || failure() ) run: | - set -o pipefail - files=$(echo "${{ steps.random-files.outputs.files }}" | tr ',' '\n' | grep -E '\.d\.ts$' | tr '\n' ' ' || true) + files=$(echo "${{ steps.random-files.outputs.files }}" | tr ',' '\n' | grep -E '\.d\.ts$' | tr '\n' ' ') if [[ -n "${files}" ]]; then make TYPESCRIPT_DECLARATIONS_LINTER=eslint lint-typescript-declarations-files FAST_FAIL=0 FILES="${files}" 2>&1 | tee lint_typescript_declarations_errors.txt - else - echo "No TypeScript declaration files to lint." fi # Create sub-issue for TypeScript declarations lint failures: