Skip to content

Commit

Permalink
Show an error when status != 200
Browse files Browse the repository at this point in the history
  • Loading branch information
MacroPower committed Jun 27, 2021
1 parent 0ba6ae2 commit 3bc3282
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/sequencer/sequencer.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ func (s *FrameSequencer) Sequence(start, end int) {
maxConcurrency = numFrames
}
for i := 0; i < maxConcurrency; i++ {
go s.renderWorker(in, out)
go s.renderWorker(i, in, out)
}

for i := start; i <= end; i++ {
Expand Down Expand Up @@ -97,8 +97,8 @@ func (s *FrameSequencer) renderWorker(in <-chan frame, out chan<- error) {
fmt.Printf("Rendering frame %d\n", f.num)

b, code, err := s.Renderer(f.start, f.end)
if err != nil {
out <- fmt.Errorf("%d error: %v", code, err)
if err != nil || code != 200 {
out <- fmt.Errorf("worker %d error: code %d: %v", n, code, err)
continue
}

Expand Down

0 comments on commit 3bc3282

Please sign in to comment.