Merged
Conversation
Contributor
Homeboy Results —
|
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.
Summary
datamachine/drain-job, a synchronous Abilities API primitive for draining due Action Scheduler step work scoped to onejob_id.completed_no_itemsplus a pure-PHP smoke test for the ability contract.Fixes #1803.
Approach
I chose option C from the issue because a separate
datamachine/drain-jobability is the clean reusable primitive. Callers can composedatamachine/run-flowwithdatamachine/drain-jobwithout adding caller-mode flags to the existing async flow execution path.Testing
php -l inc/Abilities/Engine/DrainJobAbility.php && php -l inc/Abilities/EngineAbilities.php && php -l tests/drain-job-ability-smoke.php && php -l tests/Unit/Abilities/Engine/DrainJobAbilityTest.phpphp tests/drain-job-ability-smoke.phpvendor/bin/phpcs inc/Abilities/Engine/DrainJobAbility.php inc/Abilities/EngineAbilities.php tests/drain-job-ability-smoke.php tests/Unit/Abilities/Engine/DrainJobAbilityTest.phphomeboy test data-machine -- --filter DrainJobAbilityTeststill ran the full Playground PHPUnit suite instead of filtering.homeboy test data-machine -- tests/Unit/Abilities/Engine/DrainJobAbilityTest.phpalso ran the full Playground PHPUnit suite instead of selecting the file.Full-suite result from those Homeboy runs: the new drain-job test passed, but the suite still has one unrelated failure:
DataMachine\Tests\Unit\Abilities\ImageGenerationPromptRefinementTest::test_refine_prompt_includes_post_context_when_providedfailing because the refined prompt is empty and does not containArticle context:.AI assistance