Skip to content

Commit d0b8e58

Browse files
committed
chore: note about re-marshaling
Signed-off-by: Danny Kopping <danny@coder.com>
1 parent cd10bd4 commit d0b8e58

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

intercept/responses/blocking.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,9 @@ func (i *BlockingResponsesInterceptor) handleInnerAgenticLoop(ctx context.Contex
138138
i.prepareRequestForAgenticLoop(response)
139139
i.req.Input.OfInputItemList = append(i.req.Input.OfInputItemList, results...)
140140

141+
// TODO: we should avoid re-marshaling Input, but since it changes from a string to
142+
// a list in this loop, we have to.
143+
// See responsesInterceptionBase.requestOptions for more details about marshaling issues.
141144
i.reqPayload, err = sjson.SetBytes(i.reqPayload, "input", i.req.Input)
142145
if err != nil {
143146
i.logger.Error(ctx, "failure to marshal new input in inner agentic loop", slog.Error(err))

0 commit comments

Comments
 (0)