feat(cli): per-flow artifact folders + single-flow manifest#3345
Merged
proksh merged 5 commits intoJun 9, 2026
Merged
Conversation
…est, consistent mkdir
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.
Stacked on the artifact-manifest PR. Restructures the CLI's debug output from a flat session dir into per-flow folders, and migrates the single-flow run path so it produces a manifest too.
Why
Today the CLI flattens every flow's artifacts into one
~/.maestro/tests/<ts>/dir with flow-suffixed names (commands-(login).json), so a large multi-flow upload is an unreadable pile, the per-flowmanifest.jsonclobbers (only the last flow survives), and a single-flowmaestro test x.yamlproduces no manifest at all (it ran through the un-migratedrunSingle/saveFlowpath).What
~/.maestro/tests/<ts>/<flow>/with clean names. NewTestDebugReporter.copyBundleToFlowDir(recursive copy; folder = sanitized flow name,-shard-Nwhen sharded,-Non collision) replacescopyToFlatLayout(deleted, along with its rename + manifest-rewrite machinery). The manifest's relative paths are already correct, so it's copied verbatim — no rewriting.MaestroCommandRunner.runCommandsgainsartifactsDirand returnsOrchestra.FlowResult;runSinglenow produces a bundle and writes a per-flow folder + manifest, just like the suite path.saveFlowis removed (its only caller).runContinuousis unchanged (artifactsDir = null).ArtifactsGeneratorowns the failure screenshot (into the bundle);MaestroCommandRunnerdrops only itsonCommandFailedcapture but keeps WARNED + analyze per-command captures, whichrunSinglepersists into the flow folder viapersistDebugScreenshots— so no duplicate failure shot, and analyze/warned coverage is preserved.Result (verified on a real iOS sim)
maestro test single.yaml→<ts>/single/{commands.json, maestro.log, manifest.json, screenshot-❌-*.png}— manifest now present (COMMAND_METADATA, MAESTRO_LOG, SCREENSHOT).maestro test <workspace>→<ts>/flow_a/and<ts>/flow_b/, each with its ownmanifest.json— no clobber.Notes / for reviewer
~/.maestro/tests/layout (flat → nested) and does therunSingle→ listener/artifactsDirmigration that feat: orchestra artifacts listener API + CLI migration (Phase 0+1) #3282 deferred — both squarely in your area, flagging for awareness.TestAnalysisManager.processDebugFilesuses a recursiveFiles.walkand matches by filename; the MCPlogsDirandCloudInteractoruse the session root.--flatten-debug-output(root-location) semantics unchanged.maestro.logfromLogConfig, the driver'sxctest_runner.log) remain session-level and are not in the per-flow manifest — they're produced below Orchestra; unifying those is a separate device-artifact-seam follow-up.Tests
:maestro-cli:testgreen (newcopyBundleToFlowDir+persistDebugScreenshotstests; oldcopyToFlatLayout/saveFlowtests removed).iphone_11_ios_17.