| 849 | * @since 4.0.0 |
| 850 | */ |
| 851 | export class UnsupportedSchemaError extends Schema.Error<UnsupportedSchemaError>( |
| 852 | "effect/ai/AiError/UnsupportedSchemaError" |
| 853 | )({ |
| 854 | _tag: Schema.tag("UnsupportedSchemaError"), |
| 855 | description: Schema.String, |
| 856 | metadata: providerMetadataWithDefaults<UnsupportedSchemaErrorMetadata>() |
| 857 | }) { |
| 858 | /** |
| 859 | * Marks `UnsupportedSchemaError` as a semantic AI error reason for runtime guards. |
| 860 | * |
| 861 | * @since 4.0.0 |
| 862 | */ |
| 863 | readonly [ReasonTypeId] = ReasonTypeId |
| 864 | |
| 865 | /** |
| 866 | * Unsupported schema errors are not retryable because they indicate a programmer error. |
| 867 | * |
| 868 | * @since 4.0.0 |
| 869 | */ |
| 870 | get isRetryable(): boolean { |
| 871 | return false |
| 872 | } |
| 873 | |
| 874 | override get message(): string { |
| 875 | return `Unsupported schema: ${this.description}` |
| 876 | } |
| 877 | } |
| 878 | |
| 879 | /** |
| 880 | * Error data for unknown or unexpected AI failures. |
nothing calls this directly
no test coverage detected