@@ -67,7 +67,11 @@ import {
6767 type QaCredentialRecord ,
6868} from "./qa-credentials-admin.runtime.js" ;
6969import { normalizeQaThinkingLevel , type QaThinkingLevel } from "./qa-gateway-config.js" ;
70- import { normalizeQaTransportId , type QaTransportId } from "./qa-transport-registry.js" ;
70+ import {
71+ normalizeQaTransportId ,
72+ qaTransportSupportsModuleFlows ,
73+ type QaTransportId ,
74+ } from "./qa-transport-registry.js" ;
7175import {
7276 defaultQaModelForMode ,
7377 normalizeQaProviderMode ,
@@ -663,6 +667,8 @@ export async function runQaProfileCommand(opts: QaProfileCommandOptions) {
663667 ...scenarioPack . scenarios . filter ( ( scenario ) => missingScenarioIdSet . has ( scenario . id ) ) ,
664668 ]
665669 : taxonomyScenarios ;
670+ const liveAdapterFactories =
671+ profileReport . channelDriver === "live" ? listLiveTransportQaAdapterFactories ( ) : undefined ;
666672 const executionSelection = resolveQaRunProfileExecutionSelection ( {
667673 scenarios : executionScenarios ,
668674 providerMode : normalizedProviderMode ,
@@ -672,6 +678,16 @@ export async function runQaProfileCommand(opts: QaProfileCommandOptions) {
672678 profileReport . channelDriver === "crabline" ? OPENCLAW_CRABLINE_DEFAULT_CHANNEL : undefined ,
673679 supportsChannel :
674680 profileReport . channelDriver === "crabline" ? isCrablineServerChannel : undefined ,
681+ resolveModuleFlowSupport :
682+ profileReport . channelDriver === "live"
683+ ? ( channel ) =>
684+ channel
685+ ? qaTransportSupportsModuleFlows ( liveAdapterFactories , {
686+ channelId : channel ,
687+ driver : "live" ,
688+ } )
689+ : false
690+ : undefined ,
675691 } ) ;
676692 if ( requestedScenarioIds . length > 0 && executionSelection . excludedScenarios . length > 0 ) {
677693 const exclusions = executionSelection . excludedScenarios
@@ -852,6 +868,19 @@ export async function runQaSuiteCommand(opts: QaSuiteCommandOptions) {
852868 parityPack : opts . parityPack ,
853869 scenarioIds : opts . scenarioIds ,
854870 } ) ;
871+ const liveChannelId = channelDriver === "live" ? opts . channel ?. trim ( ) : undefined ;
872+ const liveAdapterFactories =
873+ channelDriver === "live" ? listLiveTransportQaAdapterFactories ( ) : undefined ;
874+ const resolveModuleFlowSupport =
875+ channelDriver === "live"
876+ ? ( channel ?: string ) =>
877+ channel
878+ ? qaTransportSupportsModuleFlows ( liveAdapterFactories , {
879+ channelId : channel ,
880+ driver : "live" ,
881+ } )
882+ : false
883+ : undefined ;
855884 const runtimePairLanes = parseQaRuntimePairLaneFilters ( opts . runtimePairLane ) ;
856885 const runtimePairLaneSelection = resolveQaRuntimePairLaneScenarioIds ( {
857886 channel : opts . channel ,
@@ -863,6 +892,7 @@ export async function runQaSuiteCommand(opts: QaSuiteCommandOptions) {
863892 scenarioIds : explicitScenarioIds ,
864893 runtimePairLanes,
865894 runtimePair : runtimePair !== undefined ,
895+ resolveModuleFlowSupport,
866896 } ) ;
867897 const scenarioIds = runtimePairLaneSelection . scenarioIds ;
868898 if ( runtimePair ) {
@@ -882,9 +912,6 @@ export async function runQaSuiteCommand(opts: QaSuiteCommandOptions) {
882912 if ( opts . channel ?. trim ( ) && channelDriver !== "crabline" && channelDriver !== "live" ) {
883913 throw new Error ( "--channel override requires --channel-driver crabline or live." ) ;
884914 }
885- const liveChannelId = channelDriver === "live" ? opts . channel ?. trim ( ) : undefined ;
886- const liveAdapterFactories =
887- channelDriver === "live" ? listLiveTransportQaAdapterFactories ( ) : undefined ;
888915 const liveAdapterFactory = liveChannelId
889916 ? liveAdapterFactories ?. find ( ( factory ) => factory . id === liveChannelId )
890917 : undefined ;
0 commit comments