Enforce requested adapter output paths
This commit is contained in:
@@ -139,13 +139,10 @@ func (transcribeStage) Run(ctx context.Context, env *Env, m *manifest.Manifest)
|
||||
continue
|
||||
}
|
||||
|
||||
if strings.TrimSpace(res.OutputRawTranscriptPath) == "" {
|
||||
res.OutputRawTranscriptPath = j.outPath
|
||||
}
|
||||
if filepath.Clean(res.OutputRawTranscriptPath) != filepath.Clean(j.outPath) {
|
||||
if _, err := authoritativeOutputPath(j.outPath, res.OutputRawTranscriptPath); err != nil {
|
||||
mu.Lock()
|
||||
if firstErr == nil {
|
||||
firstErr = fmt.Errorf("speaker %q: adapter output path %q did not match expected %q", j.speakerID, res.OutputRawTranscriptPath, j.outPath)
|
||||
firstErr = fmt.Errorf("speaker %q: %w", j.speakerID, err)
|
||||
cancel()
|
||||
}
|
||||
mu.Unlock()
|
||||
|
||||
Reference in New Issue
Block a user