Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
80 changes: 40 additions & 40 deletions _catalog/dotnet-go-sdk-symbol-mapping.json
Original file line number Diff line number Diff line change
Expand Up @@ -13310,90 +13310,90 @@
"mapping": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"properties": {
"AllToolsAutoApprovalRule": {
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"ReadOnlyToolsAutoApprovalRule": {
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"StateKeys": {
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
}
},
"methods": {
"Dispose() -> void": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
}
},
"constructors": {
"FileAccessProvider(AgentFileStore, FileAccessProviderOptions)": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
}
},
"constants": {
"DeleteFileToolName": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"GrepToolName": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"LsToolName": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"ReadFileToolName": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"ReadLinesToolName": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"ReplaceLinesToolName": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"ReplaceToolName": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
},
"WriteToolName": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProvider is marked MAAI001 experimental."
}
}
},
Expand All @@ -13404,37 +13404,37 @@
"mapping": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProviderOptions is marked MAAI001 experimental."
},
"properties": {
"DisableReadOnlyToolApproval": {
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProviderOptions is marked MAAI001 experimental."
},
"DisableWriteToolApproval": {
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProviderOptions is marked MAAI001 experimental."
},
"DisableWriteTools": {
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProviderOptions is marked MAAI001 experimental."
},
"Instructions": {
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProviderOptions is marked MAAI001 experimental."
}
},
"constructors": {
"FileAccessProviderOptions()": {
"go": "",
"go_symbols": [],
"status": "unmapped",
"unreviewed": true
"status": "intentional",
"note": "Intentionally omitted from the Go 0.2.0 non-experimental harness scope because FileAccessProviderOptions is marked MAAI001 experimental."
}
}
},
Expand Down
5 changes: 4 additions & 1 deletion agent/context_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,10 @@ func TestContextProviderMiddleware_Run_SuppressesInvokedErrorAfterConsumerStop(t
// returns an error; the middleware must not yield it because the consumer
// already stopped, otherwise Go panics with
// "range function continued iteration after loop body returned false".
for range seq {
for _, err := range seq {
if err != nil {
t.Fatalf("middleware returned an error: %v", err)
}
break
}
}
Expand Down
5 changes: 4 additions & 1 deletion agent/logger_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,10 @@ func TestAgent_RunLogs_EarlyTermination(t *testing.T) {
})

consumedCount := 0
for range a.RunText(context.Background(), "hello") {
for _, err := range a.RunText(context.Background(), "hello") {
if err != nil {
t.Fatal(err)
}
consumedCount++
if consumedCount >= 2 {
break
Expand Down
4 changes: 3 additions & 1 deletion provider/openaiprovider/chat_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -694,7 +694,9 @@ func TestChatAgentConfigAllowsConcurrentToolInvocation(t *testing.T) {
case <-started:
case <-time.After(time.Second):
close(release)
<-done
if err := <-done; err != nil {
t.Errorf("tool run after releasing calls: %v", err)
}
t.Fatal("tool calls did not start concurrently")
}
}
Expand Down
74 changes: 60 additions & 14 deletions provider/otelprovider/otel_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,10 @@ func TestOtel_Run_DoesNotRecordUnreportedTokenUsage(t *testing.T) {
}
}

for range mw.Run(next, t.Context(), nil) {
for _, err := range mw.Run(next, t.Context(), nil) {
if err != nil {
t.Fatal(err)
}
}

resourceMetrics := collectMetrics(t, reader)
Expand All @@ -244,7 +247,10 @@ func TestOtel_Run_DoesNotRecordEmptyUsageContent(t *testing.T) {
}
}

for range mw.Run(next, t.Context(), nil) {
for _, err := range mw.Run(next, t.Context(), nil) {
if err != nil {
t.Fatal(err)
}
}

resourceMetrics := collectMetrics(t, reader)
Expand All @@ -267,7 +273,10 @@ func TestOtel_Run_DoesNotRecordTokenMetricForOptionalCountersOnly(t *testing.T)
}
}

for range mw.Run(next, t.Context(), nil) {
for _, err := range mw.Run(next, t.Context(), nil) {
if err != nil {
t.Fatal(err)
}
}

resourceMetrics := collectMetrics(t, reader)
Expand All @@ -288,7 +297,10 @@ func TestOtel_Run_MetricErrorAttributes(t *testing.T) {
}
}

for range mw.Run(next, t.Context(), nil) {
for _, err := range mw.Run(next, t.Context(), nil) {
if !errors.Is(err, testErr) {
t.Fatalf("middleware error = %v, want %v", err, testErr)
}
}

resourceMetrics := collectMetrics(t, reader)
Expand Down Expand Up @@ -339,7 +351,10 @@ func TestOtel_Run_RecordsMetricsOnEarlyBreak(t *testing.T) {
}
}

for range mw.Run(next, t.Context(), nil) {
for _, err := range mw.Run(next, t.Context(), nil) {
if err != nil {
t.Fatal(err)
}
break
}

Expand Down Expand Up @@ -368,7 +383,10 @@ func TestOtel_Run_CreatesSpan(t *testing.T) {
messages := []*message.Message{message.NewText("test message")}

seq := mw.Run(next, t.Context(), messages)
for range seq {
for _, err := range seq {
if err != nil {
t.Fatal(err)
}
}

if !nextCalled {
Expand Down Expand Up @@ -592,7 +610,10 @@ func TestOtel_Run_RecordsError(t *testing.T) {
messages := []*message.Message{message.NewText("test message")}

seq := mw.Run(next, t.Context(), messages)
for range seq {
for _, err := range seq {
if !errors.Is(err, testErr) {
t.Fatalf("middleware error = %v, want %v", err, testErr)
}
}

spans := exporter.GetSpans()
Expand Down Expand Up @@ -647,7 +668,10 @@ func TestOtel_Run_CustomSourceName(t *testing.T) {
}

seq := mw.Run(next, t.Context(), []*message.Message{})
for range seq {
for _, err := range seq {
if err != nil {
t.Fatal(err)
}
}

spans := exporter.GetSpans()
Expand All @@ -673,7 +697,10 @@ func TestOtel_Run_DefaultSourceName(t *testing.T) {
}

seq := mw.Run(next, t.Context(), []*message.Message{})
for range seq {
for _, err := range seq {
if err != nil {
t.Fatal(err)
}
}

spans := exporter.GetSpans()
Expand Down Expand Up @@ -701,7 +728,10 @@ func TestOtel_Run_PropagatesContext(t *testing.T) {
}

seq := mw.Run(next, t.Context(), []*message.Message{})
for range seq {
for _, err := range seq {
if err != nil {
t.Fatal(err)
}
}

if capturedCtx == nil {
Expand Down Expand Up @@ -737,7 +767,10 @@ func TestOtel_Run_HandlesMultipleUpdates(t *testing.T) {
}

seq := mw.Run(next, t.Context(), []*message.Message{})
for range seq {
for _, err := range seq {
if err != nil {
t.Fatal(err)
}
updateCount++
}

Expand Down Expand Up @@ -980,7 +1013,10 @@ func TestOtel_Run_HandlesEarlyBreak(t *testing.T) {
seq := mw.Run(next, t.Context(), []*message.Message{})

count := 0
for range seq {
for _, err := range seq {
if err != nil {
t.Fatal(err)
}
count++
if count >= 3 {
break
Expand Down Expand Up @@ -1011,7 +1047,10 @@ func TestOtel_Run_UnknownProviderWhenNoMetadata(t *testing.T) {

// Use context without metadata
seq := mw.Run(next, t.Context(), []*message.Message{})
for range seq {
for _, err := range seq {
if err != nil {
t.Fatal(err)
}
}

spans := exporter.GetSpans()
Expand Down Expand Up @@ -1049,7 +1088,14 @@ func TestOtel_Run_RecordsMultipleErrors(t *testing.T) {
}

seq := mw.Run(next, t.Context(), []*message.Message{})
for range seq {
wantErrors := []error{err1, err2}
for _, err := range seq {
if callCount >= len(wantErrors) {
t.Fatalf("received more than %d errors", len(wantErrors))
}
if !errors.Is(err, wantErrors[callCount]) {
t.Errorf("error %d = %v, want %v", callCount, err, wantErrors[callCount])
}
callCount++
}

Expand Down
10 changes: 8 additions & 2 deletions vectordata/helpers_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,10 @@ func TestGetBatch_NativeStopsOnConsumerBreakAndError(t *testing.T) {
}
}
}}
for range vectordata.GetBatch(t.Context(), collection, []string{"first", "second"}, nil) {
for _, err := range vectordata.GetBatch(t.Context(), collection, []string{"first", "second"}, nil) {
if !errors.Is(err, failure) {
t.Fatalf("GetBatch error = %v, want %v", err, failure)
}
break
}
if calls != 1 {
Expand All @@ -216,7 +219,10 @@ func TestGetBatch_NativeStopsOnConsumerBreakAndError(t *testing.T) {
func TestBatchHelpers_EmptyAndInvalidInputs(t *testing.T) {
collection := &nativeCollection{}
for _, keys := range [][]string{nil, {}} {
for range vectordata.GetBatch(t.Context(), collection, keys, nil) {
for _, err := range vectordata.GetBatch(t.Context(), collection, keys, nil) {
if err != nil {
t.Fatal(err)
}
t.Fatal("empty retrieval yielded a value")
}
if err := vectordata.DeleteBatch(t.Context(), collection, keys); err != nil {
Expand Down
Loading
Loading