bugfix: create spans for nested tasks in gather, rasa, and dial; fix gather bug not starting transcribe after say completes

This commit is contained in:
Dave Horton
2022-03-29 15:44:55 -04:00
parent 6e4ae69cb7
commit ff8d7f3648
5 changed files with 56 additions and 8 deletions

View File

@@ -226,7 +226,11 @@ class TaskDial extends Task {
this.logger.debug('Dial:whisper executing tasks');
while (tasks.length && !cs.callGone) {
const task = tasks.shift();
const {span, ctx} = this.startChildSpan(`whisper:${this.sayTask.summary}`);
task.span = span;
task.ctx = ctx;
await task.exec(cs, callSid === this.callSid ? this.ep : this.epOther);
span.end();
}
this.logger.debug('Dial:whisper tasks complete');
if (!cs.callGone && this.epOther) {