HDDS-16010. Fix lint silently failing and fix existing lint errors - #516
Merged
Conversation
Contributor
Author
|
cc @yuriipalam |
errose28
marked this pull request as ready for review
July 28, 2026 17:22
Address remaining MD044/MD029/MD028 issues in docs added on master after the initial lint sweep. Co-authored-by: Cursor <cursoragent@cursor.com>
errose28
commented
Jul 28, 2026
…-short-circuit-local-reads.md Co-authored-by: Ethan Rose <33912936+errose28@users.noreply.github.com>
…03-merged-branches/16-hdds-8342-s3-lifecycle-configurations.md Co-authored-by: Ethan Rose <33912936+errose28@users.noreply.github.com>
Keeps template steps in order when blockquotes and notes sit between sections. Co-authored-by: Cursor <cursoragent@cursor.com>
adoroszlai
approved these changes
Jul 29, 2026
Contributor
|
Thanks @errose28, @jojochuang for the patch. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
Problem
Since HDDS-14546, CI has been passing even with lint errors because pnpm run lint always returns 0. It is defined as
Claude's explanation which is more thorough than mine:
The three tools are chained with ;, not &&. In a shell, a ;-separated sequence returns the exit code of the last command only. So:
eslint fails → non-zero code, but ignored; next command runs anyway.
markdownlint fails → non-zero code, but ignored; next command runs anyway.
The overall exit code of pnpm run lint = whatever yamllint returns.
So unless yamllint itself fails, the Run lint step exits 0 and CI stays green — even with eslint or markdownlint errors present. markdownlint is genuinely running (you'd see its errors in the log output), but its failure is swallowed.
Fixes
Use an
rcvariable to track the aggregate return code of all commands inpnpm run lint. It starts as 0 and is set to 1 if any commands fail.Update markdownlint capitalization check to allow "s3" as lowercase when it is not used in sentences (preceded by a space). This matches the convention for other words there like "ozone".
eslint has been silently failing since it was added in HDDS-14770.
unrs-resolveractually requires a package it declares as optional (seems like an upstream mistake but we are stuck with it either way). Lint checks were installing dependencies with--devto avoid installing build tools not required at that stage, but this also drops optional dependencies.Added
--frozen-lockfileto all static check install commands so that they use the pinned versions.All existing lint errors that previously slipped in have been fixed in this PR.
What is the link to the Apache Jira?
HDDS-16010
How was this patch tested?
pnpm run lint: