Skip to content

fix : correct exit status logic in registry_validator __main__ - #1847

Closed
tmdeveloper007 wants to merge 1 commit into
steam-bell-92:mainfrom
tmdeveloper007:#1843
Closed

fix : correct exit status logic in registry_validator __main__#1847
tmdeveloper007 wants to merge 1 commit into
steam-bell-92:mainfrom
tmdeveloper007:#1843

Conversation

@tmdeveloper007

Copy link
Copy Markdown
Contributor

Summary of What Has Been Done

Restructured the exit status logic in utils/registry_validator.py __main__ block to use a single clear conditional instead of a confusing two-step pattern.

Changes Made

  • Replaced the separate early if args.strict and validator.warnings: sys.exit(1) check and the sys.exit(1 if validator.errors else 0) final call with a single unified conditional:
    if validator.errors or (args.strict and validator.warnings):
        sys.exit(1)
    sys.exit(0)

Impact it Made

  • Correctly exits with code 0 when there are no errors (and no strict-mode warnings)
  • Correctly exits with code 1 when there are errors OR when --strict is used and warnings are present
  • Makes the exit code logic readable and unambiguous for CI/CD pipelines

Closes #1843

Note: Please assign this PR to the tmdeveloper007 account.

@vercel

vercel Bot commented Jul 29, 2026

Copy link
Copy Markdown

@tmdeveloper007 is attempting to deploy a commit to the Anuj's projects Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix : correct strict-mode exit status when only warnings are present in registry_validator.py

2 participants