(ctx context.Context)
| 232 | } |
| 233 | |
| 234 | func (node *ModTreeNode) runCheckLocally(ctx context.Context) error { |
| 235 | var status dagql.AnyResult |
| 236 | if err := node.DagqlValue(ctx, &status); err != nil { |
| 237 | return err |
| 238 | } |
| 239 | if obj, ok := dagql.UnwrapAs[dagql.AnyObjectResult](status); ok { |
| 240 | // If the check returns a syncable type, sync it |
| 241 | srv := node.DagqlServer |
| 242 | if syncField, has := obj.ObjectType().FieldSpec("sync", srv.View); has { |
| 243 | if !syncField.Args.HasRequired(srv.View) { |
| 244 | if err := srv.Select( |
| 245 | dagql.WithNonInternalTelemetry(ctx), |
| 246 | obj, |
| 247 | &status, |
| 248 | dagql.Selector{Field: "sync"}, |
| 249 | ); err != nil { |
| 250 | return err |
| 251 | } |
| 252 | } |
| 253 | } |
| 254 | } |
| 255 | return nil |
| 256 | } |
| 257 | |
| 258 | func (node *ModTreeNode) tryRunCheckScaleOut(ctx context.Context) (_ bool, rerr error) { |
| 259 | q, err := CurrentQuery(ctx) |
no test coverage detected