Repository navigation
feat(sim): share the simulation runner with the host repos - #78
Merged
Merged
Conversation
…im config with the host repos runSimulation runs one judged case end to end (pessimistic sidecar, wait hand-over, silent passes, dialogs, validity guards, provider and dev server errors). The host keeps its cases, seeding, login and what the person sees. Also exported: captureGatewayErrors (401/403 left to the judge), bridgeSettings/seedAgentsSettings/assertBridgeUp, passActions/withSilentPasses, CHAT_FRAME/ensureChatOpen, defineSimConfig, reportCli and simCaseNames. The unit tests of data-fair, portals and catalogs move here with them.
… need a real browser
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.
Move into
@data-fair/lib-agents-simthe simulation runner that data-fair, portals and catalogs each copied:runSimulation(page, simCase, { agentsUrl, locale, setup, perceptionRoots })runs one judged case end to end: pessimistic sidecar,wait_for_user_actionhand-over, silent passes, accepted dialogs,SIM_SUB_AGENTS=0, validity guards (provider error, cold Vite dev server, empty transcript, no gateway exchange). The host keeps its cases, seeding, login and what the person sees.captureGatewayErrors/errorsInSseBody/errorsInResponse,bridgeSettings/seedAgentsSettings/assertBridgeUp,passActions/withSilentPasses,CHAT_FRAME/ensureChatOpen,defineSimConfig,reportCli,simCaseNames.tests/features/lib-sim/runner-helpers.unit.spec.ts; the barrel test lists the new exports.Why: catalogs, the third consumer, copied 536 of its 556 runner lines from portals, and the copies had drifted (data-fair had no silent passes, an older drawer probe, and counted 401/403 as provider errors).
Heads-up: behaviour is portals' and catalogs' where the copies differed: 401/403 are left to the judge, every quota role is unlimited, dialogs are accepted. The agents repo's own simulations keep their loop (the chat is the page there, not a frame). Each host switches in its own PR after the 0.11.0 release.