MCPcopy Create free account
hub / github.com/cel-expr/cel-go / BypassAsyncProtection

Function BypassAsyncProtection

cel/options.go:863–868  ·  view source on GitHub ↗

BypassAsyncProtection allows for the bypass of hasAsync protection in Eval and ContextEval if present. By default, expressions in an environment with asynchronous functions will reject calls to Eval and ContextEval, requiring ConcurrentEval instead. This option bypasses that check, allowing synchro

()

Source from the content-addressed store, hash-verified

861// synchronous evaluation of expressions that do not actually call asynchronous functions (such as
862// constant validations).
863func BypassAsyncProtection() ProgramOption {
864 return func(p *prog) (*prog, error) {
865 p.hasAsync = false
866 return p, nil
867 }
868}
869
870// CostEstimatorOptions configure type-check time options for estimating expression cost.
871func CostEstimatorOptions(costOpts ...cost.CostOption) EnvOption {

Callers 2

evalCallFunction · 0.85

Calls

no outgoing calls

Tested by 1