chore(effect): update to beta.107 (#43109)
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { Schema } from "effect"
|
||||
import { Skill } from "@opencode-ai/schema/skill"
|
||||
|
||||
export class InvalidRequestError extends Schema.TaggedErrorClass<InvalidRequestError>()(
|
||||
export class InvalidRequestError extends Schema.TaggedError<InvalidRequestError>()(
|
||||
"InvalidRequestError",
|
||||
{
|
||||
message: Schema.String,
|
||||
@@ -11,13 +11,13 @@ export class InvalidRequestError extends Schema.TaggedErrorClass<InvalidRequestE
|
||||
{ httpApiStatus: 400 },
|
||||
) {}
|
||||
|
||||
export class UnauthorizedError extends Schema.TaggedErrorClass<UnauthorizedError>()(
|
||||
export class UnauthorizedError extends Schema.TaggedError<UnauthorizedError>()(
|
||||
"UnauthorizedError",
|
||||
{ message: Schema.String },
|
||||
{ httpApiStatus: 401 },
|
||||
) {}
|
||||
|
||||
export class ConflictError extends Schema.TaggedErrorClass<ConflictError>()(
|
||||
export class ConflictError extends Schema.TaggedError<ConflictError>()(
|
||||
"ConflictError",
|
||||
{
|
||||
message: Schema.String,
|
||||
@@ -26,7 +26,7 @@ export class ConflictError extends Schema.TaggedErrorClass<ConflictError>()(
|
||||
{ httpApiStatus: 409 },
|
||||
) {}
|
||||
|
||||
export class SessionBusyError extends Schema.TaggedErrorClass<SessionBusyError>()(
|
||||
export class SessionBusyError extends Schema.TaggedError<SessionBusyError>()(
|
||||
"SessionBusyError",
|
||||
{
|
||||
sessionID: Schema.String,
|
||||
@@ -35,7 +35,7 @@ export class SessionBusyError extends Schema.TaggedErrorClass<SessionBusyError>(
|
||||
{ httpApiStatus: 409 },
|
||||
) {}
|
||||
|
||||
export class ServiceUnavailableError extends Schema.TaggedErrorClass<ServiceUnavailableError>()(
|
||||
export class ServiceUnavailableError extends Schema.TaggedError<ServiceUnavailableError>()(
|
||||
"ServiceUnavailableError",
|
||||
{
|
||||
message: Schema.String,
|
||||
@@ -44,7 +44,7 @@ export class ServiceUnavailableError extends Schema.TaggedErrorClass<ServiceUnav
|
||||
{ httpApiStatus: 503 },
|
||||
) {}
|
||||
|
||||
export class UnknownError extends Schema.TaggedErrorClass<UnknownError>()(
|
||||
export class UnknownError extends Schema.TaggedError<UnknownError>()(
|
||||
"UnknownError",
|
||||
{
|
||||
message: Schema.String,
|
||||
@@ -53,7 +53,7 @@ export class UnknownError extends Schema.TaggedErrorClass<UnknownError>()(
|
||||
{ httpApiStatus: 500 },
|
||||
) {}
|
||||
|
||||
export class ProviderNotFoundError extends Schema.TaggedErrorClass<ProviderNotFoundError>()(
|
||||
export class ProviderNotFoundError extends Schema.TaggedError<ProviderNotFoundError>()(
|
||||
"ProviderNotFoundError",
|
||||
{
|
||||
providerID: Schema.String,
|
||||
@@ -62,7 +62,7 @@ export class ProviderNotFoundError extends Schema.TaggedErrorClass<ProviderNotFo
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class AgentNotFoundError extends Schema.TaggedErrorClass<AgentNotFoundError>()(
|
||||
export class AgentNotFoundError extends Schema.TaggedError<AgentNotFoundError>()(
|
||||
"AgentNotFoundError",
|
||||
{
|
||||
agentID: Schema.String,
|
||||
@@ -71,7 +71,7 @@ export class AgentNotFoundError extends Schema.TaggedErrorClass<AgentNotFoundErr
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class SessionNotFoundError extends Schema.TaggedErrorClass<SessionNotFoundError>()(
|
||||
export class SessionNotFoundError extends Schema.TaggedError<SessionNotFoundError>()(
|
||||
"SessionNotFoundError",
|
||||
{
|
||||
sessionID: Schema.String,
|
||||
@@ -80,7 +80,7 @@ export class SessionNotFoundError extends Schema.TaggedErrorClass<SessionNotFoun
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class MessageNotFoundError extends Schema.TaggedErrorClass<MessageNotFoundError>()(
|
||||
export class MessageNotFoundError extends Schema.TaggedError<MessageNotFoundError>()(
|
||||
"MessageNotFoundError",
|
||||
{
|
||||
sessionID: Schema.String,
|
||||
@@ -90,7 +90,7 @@ export class MessageNotFoundError extends Schema.TaggedErrorClass<MessageNotFoun
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class SkillNotFoundError extends Schema.TaggedErrorClass<SkillNotFoundError>()(
|
||||
export class SkillNotFoundError extends Schema.TaggedError<SkillNotFoundError>()(
|
||||
"SkillNotFoundError",
|
||||
{
|
||||
skill: Skill.ID,
|
||||
@@ -99,7 +99,7 @@ export class SkillNotFoundError extends Schema.TaggedErrorClass<SkillNotFoundErr
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class McpServerNotFoundError extends Schema.TaggedErrorClass<McpServerNotFoundError>()(
|
||||
export class McpServerNotFoundError extends Schema.TaggedError<McpServerNotFoundError>()(
|
||||
"McpServerNotFoundError",
|
||||
{
|
||||
server: Schema.String,
|
||||
@@ -108,7 +108,7 @@ export class McpServerNotFoundError extends Schema.TaggedErrorClass<McpServerNot
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class CommandNotFoundError extends Schema.TaggedErrorClass<CommandNotFoundError>()(
|
||||
export class CommandNotFoundError extends Schema.TaggedError<CommandNotFoundError>()(
|
||||
"CommandNotFoundError",
|
||||
{
|
||||
command: Schema.String,
|
||||
@@ -117,7 +117,7 @@ export class CommandNotFoundError extends Schema.TaggedErrorClass<CommandNotFoun
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class CommandEvaluationError extends Schema.TaggedErrorClass<CommandEvaluationError>()(
|
||||
export class CommandEvaluationError extends Schema.TaggedError<CommandEvaluationError>()(
|
||||
"CommandEvaluationError",
|
||||
{
|
||||
command: Schema.String,
|
||||
@@ -126,13 +126,13 @@ export class CommandEvaluationError extends Schema.TaggedErrorClass<CommandEvalu
|
||||
{ httpApiStatus: 500 },
|
||||
) {}
|
||||
|
||||
export class InvalidCursorError extends Schema.TaggedErrorClass<InvalidCursorError>()(
|
||||
export class InvalidCursorError extends Schema.TaggedError<InvalidCursorError>()(
|
||||
"InvalidCursorError",
|
||||
{ message: Schema.String },
|
||||
{ httpApiStatus: 400 },
|
||||
) {}
|
||||
|
||||
export class PermissionNotFoundError extends Schema.TaggedErrorClass<PermissionNotFoundError>()(
|
||||
export class PermissionNotFoundError extends Schema.TaggedError<PermissionNotFoundError>()(
|
||||
"PermissionNotFoundError",
|
||||
{
|
||||
requestID: Schema.String,
|
||||
@@ -141,7 +141,7 @@ export class PermissionNotFoundError extends Schema.TaggedErrorClass<PermissionN
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class FormNotFoundError extends Schema.TaggedErrorClass<FormNotFoundError>()(
|
||||
export class FormNotFoundError extends Schema.TaggedError<FormNotFoundError>()(
|
||||
"FormNotFoundError",
|
||||
{
|
||||
id: Schema.String,
|
||||
@@ -150,7 +150,7 @@ export class FormNotFoundError extends Schema.TaggedErrorClass<FormNotFoundError
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class FormAlreadySettledError extends Schema.TaggedErrorClass<FormAlreadySettledError>()(
|
||||
export class FormAlreadySettledError extends Schema.TaggedError<FormAlreadySettledError>()(
|
||||
"FormAlreadySettledError",
|
||||
{
|
||||
id: Schema.String,
|
||||
@@ -159,7 +159,7 @@ export class FormAlreadySettledError extends Schema.TaggedErrorClass<FormAlready
|
||||
{ httpApiStatus: 409 },
|
||||
) {}
|
||||
|
||||
export class FormInvalidAnswerError extends Schema.TaggedErrorClass<FormInvalidAnswerError>()(
|
||||
export class FormInvalidAnswerError extends Schema.TaggedError<FormInvalidAnswerError>()(
|
||||
"FormInvalidAnswerError",
|
||||
{
|
||||
id: Schema.String,
|
||||
@@ -168,13 +168,13 @@ export class FormInvalidAnswerError extends Schema.TaggedErrorClass<FormInvalidA
|
||||
{ httpApiStatus: 400 },
|
||||
) {}
|
||||
|
||||
export class ForbiddenError extends Schema.TaggedErrorClass<ForbiddenError>()(
|
||||
export class ForbiddenError extends Schema.TaggedError<ForbiddenError>()(
|
||||
"ForbiddenError",
|
||||
{ message: Schema.String },
|
||||
{ httpApiStatus: 403 },
|
||||
) {}
|
||||
|
||||
export class PtyNotFoundError extends Schema.TaggedErrorClass<PtyNotFoundError>()(
|
||||
export class PtyNotFoundError extends Schema.TaggedError<PtyNotFoundError>()(
|
||||
"PtyNotFoundError",
|
||||
{
|
||||
ptyID: Schema.String,
|
||||
@@ -183,7 +183,7 @@ export class PtyNotFoundError extends Schema.TaggedErrorClass<PtyNotFoundError>(
|
||||
{ httpApiStatus: 404 },
|
||||
) {}
|
||||
|
||||
export class ShellNotFoundError extends Schema.TaggedErrorClass<ShellNotFoundError>()(
|
||||
export class ShellNotFoundError extends Schema.TaggedError<ShellNotFoundError>()(
|
||||
"ShellNotFoundError",
|
||||
{
|
||||
id: Schema.String,
|
||||
|
||||
@@ -5,7 +5,7 @@ import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/un
|
||||
|
||||
const root = "/api/worktree/:projectID"
|
||||
|
||||
export class WorktreeError extends Schema.ErrorClass<WorktreeError>("WorktreeError")(
|
||||
export class WorktreeError extends Schema.Error<WorktreeError>("WorktreeError")(
|
||||
{
|
||||
name: Schema.Literal("WorktreeError"),
|
||||
data: Schema.Struct({
|
||||
|
||||
@@ -60,7 +60,7 @@ export namespace JsonRpc {
|
||||
}
|
||||
}
|
||||
|
||||
export class SimulationRequestError extends Schema.TaggedErrorClass<SimulationRequestError>()(
|
||||
export class SimulationRequestError extends Schema.TaggedError<SimulationRequestError>()(
|
||||
"SimulationRequestError",
|
||||
{
|
||||
method: Schema.String,
|
||||
@@ -131,7 +131,7 @@ export namespace Handshake {
|
||||
readonly capabilities: ReadonlyArray<Capability>
|
||||
}
|
||||
|
||||
export class RoleMismatchError extends Schema.TaggedErrorClass<RoleMismatchError>()(
|
||||
export class RoleMismatchError extends Schema.TaggedError<RoleMismatchError>()(
|
||||
"SimulationHandshake.RoleMismatchError",
|
||||
{
|
||||
expected: EndpointRole,
|
||||
@@ -140,7 +140,7 @@ export namespace Handshake {
|
||||
},
|
||||
) {}
|
||||
|
||||
export class UnsupportedProtocolError extends Schema.TaggedErrorClass<UnsupportedProtocolError>()(
|
||||
export class UnsupportedProtocolError extends Schema.TaggedError<UnsupportedProtocolError>()(
|
||||
"SimulationHandshake.UnsupportedProtocolError",
|
||||
{
|
||||
offered: Schema.Array(Schema.Number),
|
||||
@@ -149,7 +149,7 @@ export namespace Handshake {
|
||||
},
|
||||
) {}
|
||||
|
||||
export class MissingCapabilityError extends Schema.TaggedErrorClass<MissingCapabilityError>()(
|
||||
export class MissingCapabilityError extends Schema.TaggedError<MissingCapabilityError>()(
|
||||
"SimulationHandshake.MissingCapabilityError",
|
||||
{
|
||||
missing: Schema.Array(Capability),
|
||||
|
||||
Reference in New Issue
Block a user