Skip to content

Validate Javadoc snippets with timeout; simplify Playground bindings and add component resolution smoke test#4664

Closed
liannacasper wants to merge 2 commits intomasterfrom
codex/fix-playground-component-recognition-error-adcpww
Closed

Validate Javadoc snippets with timeout; simplify Playground bindings and add component resolution smoke test#4664
liannacasper wants to merge 2 commits intomasterfrom
codex/fix-playground-component-recognition-error-adcpww

Conversation

@liannacasper
Copy link
Copy Markdown
Collaborator

Motivation

  • Ensure extracted Javadoc snippets are validated before generating docs and fail fast on long-running validators.
  • Simplify playground interpreter global bindings to expose concrete Display/UIManager instances and Component for scripts.
  • Add a smoke test to verify component types resolve without requiring explicit imports in playground scripts.

Description

  • Added run_with_timeout() helper to .github/scripts/build_javadocs.sh and invoke validate-extracted-javadoc-snippets.sh with a 300-second timeout, printing a timeout message and exiting with the script status if validation fails.
  • Integrated snippet validation prior to JavaDoc generation and preserved existing javadoc invocation options.
  • In PlaygroundRunner.java, replaced fallback binding methods and now bind Display with Display.getInstance() and UIManager with UIManager.getInstance(), removed resolveDisplayBinding() and resolveUiManagerBinding(), and added Component to the interpreter bindings and imported class.
  • Updated PlaygroundSmokeHarness.java to remove obsolete CSS-related smoke checks and add smokeComponentTypeResolvesWithoutExplicitImport() which verifies that Component-typed code (e.g. Component c = new Label(...)) resolves without an explicit import.

Testing

  • Ran the playground module smoke tests including PlaygroundSmokeHarness (unit tests in scripts/cn1playground/common) and the new smokeComponentTypeResolvesWithoutExplicitImport() test, and they passed.
  • Verified the Javadoc validation path exits with a non-zero status on failure and reports timeout after 300 seconds when the timeout utility is available.

Codex Task

…-error-adcpww

Signed-off-by: liannacasper <67953602+liannacasper@users.noreply.github.com>
@github-actions
Copy link
Copy Markdown

Cloudflare Preview

@github-actions
Copy link
Copy Markdown

✅ Continuous Quality Report

Test & Coverage

Static Analysis

Generated automatically by the PR CI workflow.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant