(
input: ConnectionValueInput,
)
| 3298 | // pasted `value`/`values` are used directly; `from` origins resolve through |
| 3299 | // their provider. Single-secret sugar lands on the `token` variable. |
| 3300 | const resolveInFlightValues = ( |
| 3301 | input: ConnectionValueInput, |
| 3302 | ): Effect.Effect<Record<string, string | null>, StorageFailure> => |
| 3303 | Effect.gen(function* () { |
| 3304 | const out: Record<string, string | null> = {}; |
| 3305 | for (const { variable, origin } of normalizeConnectionInputs(input)) { |
| 3306 | if ("value" in origin) { |
| 3307 | out[variable] = origin.value; |
| 3308 | continue; |
| 3309 | } |
| 3310 | const provider = credentialProviders.get(String(origin.from.provider)); |
| 3311 | if (!provider) { |
| 3312 | return yield* new StorageError({ |
| 3313 | message: `Credential provider "${origin.from.provider}" is not registered.`, |
| 3314 | cause: undefined, |
| 3315 | }); |
| 3316 | } |
| 3317 | out[variable] = yield* provider.get(origin.from.id); |
| 3318 | } |
| 3319 | return out; |
| 3320 | }); |
| 3321 | |
| 3322 | /** Stamp the verdict + which path produced it onto the enclosing health |
| 3323 | * span. Every health outcome is HTTP 200, so WITHOUT these attributes the |
no test coverage detected