Skip to content

Remove product-specific component assumptions from generic WP Codebox adapters #768

@chubes4

Description

@chubes4

Problem

Generic WP Codebox adapter code still knows about downstream product/runtime component names.

Evidence on current origin/main:

  • Homeboy request schema is interpreted directly in the generic runner: packages/wordpress-plugin/src/class-wp-codebox-agent-sandbox-runner.php:869.
  • The ability schema describes parent_request with a Homeboy example at packages/wordpress-plugin/src/class-wp-codebox-abilities.php:190.
  • The runner and browser adapter paths still include specific component assumptions such as agents_api, data_machine, and data_machine_code in path/readiness handling.

Why It Matters

WP Codebox should remain a generic sandbox substrate. Product/orchestrator-specific request adaptation and component semantics should live in caller adapters or declared component contracts, not in the generic runtime package.

Suggested Refactor

  • Move Homeboy request normalization behind a filter/adapter such as wp_codebox_normalize_parent_task_request.
  • Replace fixed component keys/readiness checks with caller-declared component contracts and probes.
  • Keep WP Codebox responsible for packaging/install checks for declared components only.

Acceptance Criteria

  • Generic WP Codebox code does not branch on Homeboy/Data Machine-specific schemas or component names.
  • Existing consumers can provide equivalent behavior through filters/adapters.
  • Browser/runtime component smoke coverage remains green.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions