MCPcopy Index your code
hub / github.com/coder/coder / GetChatDebugStepsByRunID

Method GetChatDebugStepsByRunID

coderd/database/dbauthz/dbauthz.go:2926–2940  ·  view source on GitHub ↗
(ctx context.Context, runID uuid.UUID)

Source from the content-addressed store, hash-verified

2924}
2925
2926func (q *querier) GetChatDebugStepsByRunID(ctx context.Context, runID uuid.UUID) ([]database.ChatDebugStep, error) {
2927 run, err := q.db.GetChatDebugRunByID(ctx, runID)
2928 if err != nil {
2929 return nil, err
2930 }
2931 // Authorize via the owning chat.
2932 chat, err := q.db.GetChatByID(ctx, run.ChatID)
2933 if err != nil {
2934 return nil, err
2935 }
2936 if err := q.authorizeContext(ctx, policy.ActionRead, chat); err != nil {
2937 return nil, err
2938 }
2939 return q.db.GetChatDebugStepsByRunID(ctx, runID)
2940}
2941
2942func (q *querier) GetChatDesktopEnabled(ctx context.Context) (bool, error) {
2943 // The desktop-enabled flag is a deployment-wide setting read by any

Callers

nothing calls this directly

Calls 4

authorizeContextMethod · 0.95
GetChatDebugRunByIDMethod · 0.65
GetChatByIDMethod · 0.65

Tested by

no test coverage detected