Skip to content

Report failed clean commands#3

Open
manusss2026 wants to merge 5 commits into
benglezhenjun:mainfrom
manusss2026:codex/clean-module-failure-report-1
Open

Report failed clean commands#3
manusss2026 wants to merge 5 commits into
benglezhenjun:mainfrom
manusss2026:codex/clean-module-failure-report-1

Conversation

@manusss2026

@manusss2026 manusss2026 commented Jun 19, 2026

Copy link
Copy Markdown

/claim #1

Summary

Report failed clean commands from clean_module instead of treating every completed subprocess as a successful clean.

Changes

  • Check clean_module subprocess return codes and return False for non-zero exits.
  • Print the module name, exit status, and captured stdout/stderr when a clean command fails.
  • Keep timeout and command-not-found failures non-crashing and visible to callers.
  • Propagate clean failures through python build.py --clean with a non-zero exit code.
  • Add tools/validate_clean_module.py to demonstrate successful clean, non-zero clean, and missing-command handling.
  • Catch missing npm during the frontend prebuild install step so full diagnostic generation can finish in minimal environments.

Testing

  • python tools/validate_clean_module.py -> passed.
  • python -m py_compile build.py tools/validate_clean_module.py -> passed.
  • python build.py -> ran and generated diagnostics. The build exited 1 because this Windows environment is missing toolchains such as cargo, npm, go, gcc/g++, cmake, make, javac, ruby, luac, and ghc; those failures are captured in the diagnostic metadata.

Diagnostic artifacts committed:

  • diagnostic/build-5b7632ca.json
  • diagnostic/build-5b7632ca-part001.logd
  • diagnostic/build-5b7632ca-part002.logd
  • diagnostic/build-5b7632ca-part003.logd

Checklist

  • Relevant modules affected by these changes build locally
  • Tests pass locally
  • Diagnostic build log is committed in this PR
  • Documentation has been updated, if applicable
  • Configuration or schema changes are documented, if applicable
  • No generated build artifacts are committed, except the required diagnostic build log
  • Changes are scoped to the PR purpose and avoid unrelated cleanup
  • Security, privacy, and error-handling implications have been considered

  • I would like to request that my diagnostic build log is removed before merging

@benglezhenjun

Copy link
Copy Markdown
Owner

Please update the diagnostic metadata and rerun the validation. The current diagnostic JSON uses Windows backslash paths such as diagnostic\build-5b7632ca-part001.logd. Please regenerate diagnostics so diagnostic_logd uses repository-style forward slash paths, e.g. diagnostic/build-5b7632ca-part001.logd. Also ensure the GitHub Actions diagnostic check actually runs and passes before merge.

@manusss2026

Copy link
Copy Markdown
Author

Updated, thanks for the heads-up.

Changes pushed in 829a070:

  • build.py now emits repository-relative diagnostic paths with forward slashes via Path.as_posix().
  • Regenerated diagnostics for ae53edae; metadata now points to diagnostic/build-ae53edae-part*.logd and the reassemble/decrypt commands use / separators.
  • Removed the stale diagnostic/build-5b7632ca* bundle that contained Windows backslash paths.

Validation rerun:

  • python -m py_compile build.py tools\validate_clean_module.py
  • python tools\validate_clean_module.py
  • python build.py generated the new diagnostic bundle; local module builds still fail on this Windows runner because the toolchain commands are not installed, but the diagnostic bundle generation completed successfully.

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.

2 participants