Add stdout and stderr
This commit is contained in:
64
backend/.sqlx/query-045124ed7dd9765b61eba67f15555f33fa86d0dabebc9cd845f06c2c28ec16d7.json
generated
Normal file
64
backend/.sqlx/query-045124ed7dd9765b61eba67f15555f33fa86d0dabebc9cd845f06c2c28ec16d7.json
generated
Normal file
@@ -0,0 +1,64 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, task_id, worktree_path, base_commit, merge_commit, executor_config, created_at, updated_at \n FROM task_attempts \n WHERE task_id = $1 \n ORDER BY created_at DESC",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 1,
|
||||
"name": "task_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "worktree_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "base_commit",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"name": "merge_commit",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 5,
|
||||
"name": "executor_config",
|
||||
"type_info": "Jsonb"
|
||||
},
|
||||
{
|
||||
"ordinal": 6,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 7,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
true,
|
||||
true,
|
||||
true,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "045124ed7dd9765b61eba67f15555f33fa86d0dabebc9cd845f06c2c28ec16d7"
|
||||
}
|
||||
64
backend/.sqlx/query-0b5beec7f93c798c0de7089cb119438461d303e06dcea6db8facec1280362ef4.json
generated
Normal file
64
backend/.sqlx/query-0b5beec7f93c798c0de7089cb119438461d303e06dcea6db8facec1280362ef4.json
generated
Normal file
@@ -0,0 +1,64 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, task_id, worktree_path, base_commit, merge_commit, executor_config, created_at, updated_at \n FROM task_attempts \n WHERE id = $1",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 1,
|
||||
"name": "task_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "worktree_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "base_commit",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"name": "merge_commit",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 5,
|
||||
"name": "executor_config",
|
||||
"type_info": "Jsonb"
|
||||
},
|
||||
{
|
||||
"ordinal": 6,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 7,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
true,
|
||||
true,
|
||||
true,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "0b5beec7f93c798c0de7089cb119438461d303e06dcea6db8facec1280362ef4"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "UPDATE users SET email = $2, password_hash = $3, is_admin = $4, updated_at = $5 WHERE id = $1 RETURNING id, email, password_hash, is_admin, created_at, updated_at",
|
||||
"query": "UPDATE users SET email = $2, password_hash = $3, is_admin = $4 WHERE id = $1 RETURNING id, email, password_hash, is_admin, created_at, updated_at",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -39,8 +39,7 @@
|
||||
"Uuid",
|
||||
"Varchar",
|
||||
"Varchar",
|
||||
"Bool",
|
||||
"Timestamptz"
|
||||
"Bool"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
@@ -52,5 +51,5 @@
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "1fbd0dbbc876ac609d7fe7462a816fe3ab68b1d8711b4099daae54530d1703b1"
|
||||
"hash": "2b199ed09a8fa6e04e948afbab2400ffe768abc754434331108edfdf54a9fca7"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "INSERT INTO users (id, email, password_hash, is_admin, created_at, updated_at) VALUES ($1, $2, $3, $4, $5, $6) RETURNING id, email, password_hash, is_admin, created_at, updated_at",
|
||||
"query": "INSERT INTO users (id, email, password_hash, is_admin) VALUES ($1, $2, $3, $4) RETURNING id, email, password_hash, is_admin, created_at, updated_at",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -39,9 +39,7 @@
|
||||
"Uuid",
|
||||
"Varchar",
|
||||
"Varchar",
|
||||
"Bool",
|
||||
"Timestamptz",
|
||||
"Timestamptz"
|
||||
"Bool"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
@@ -53,5 +51,5 @@
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "34e5edf8ee8452e436a3a45837def86f078ab5b95c994b082ca48ca18154fe5f"
|
||||
"hash": "2db913b960a2fbba75c68bd8c7f2a370a3d012b5d726d03c05e27306c2e1d0cf"
|
||||
}
|
||||
53
backend/.sqlx/query-672ac4faaee68f6108f30c80ffd5d5ab73fe3e6368db416cc951a8cc67161281.json
generated
Normal file
53
backend/.sqlx/query-672ac4faaee68f6108f30c80ffd5d5ab73fe3e6368db416cc951a8cc67161281.json
generated
Normal file
@@ -0,0 +1,53 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, name, git_repo_path, owner_id, created_at, updated_at FROM projects WHERE git_repo_path = $1 AND id != $2",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 1,
|
||||
"name": "name",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "git_repo_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "owner_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 5,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Text",
|
||||
"Uuid"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "672ac4faaee68f6108f30c80ffd5d5ab73fe3e6368db416cc951a8cc67161281"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "INSERT INTO users (id, email, password_hash, is_admin, created_at, updated_at) VALUES ($1, $2, $3, $4, $5, $6)",
|
||||
"query": "INSERT INTO users (id, email, password_hash, is_admin) VALUES ($1, $2, $3, $4)",
|
||||
"describe": {
|
||||
"columns": [],
|
||||
"parameters": {
|
||||
@@ -8,12 +8,10 @@
|
||||
"Uuid",
|
||||
"Varchar",
|
||||
"Varchar",
|
||||
"Bool",
|
||||
"Timestamptz",
|
||||
"Timestamptz"
|
||||
"Bool"
|
||||
]
|
||||
},
|
||||
"nullable": []
|
||||
},
|
||||
"hash": "c120fcd1c3a0bef4640164a3d97d6dad0f11af048cca51b8acc90d8e9791abc7"
|
||||
"hash": "710c66fbde8e0c36fa0d138ba9c7e5875524ca2cbcd4fa8ddcf86d093b52349a"
|
||||
}
|
||||
69
backend/.sqlx/query-7a9cb99ac1f3aa3926fa592c5261af9a3a8f56c2dba7195c6d733e7036c81019.json
generated
Normal file
69
backend/.sqlx/query-7a9cb99ac1f3aa3926fa592c5261af9a3a8f56c2dba7195c6d733e7036c81019.json
generated
Normal file
@@ -0,0 +1,69 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "INSERT INTO task_attempts (id, task_id, worktree_path, base_commit, merge_commit, executor_config) \n VALUES ($1, $2, $3, $4, $5, $6) \n RETURNING id, task_id, worktree_path, base_commit, merge_commit, executor_config, created_at, updated_at",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 1,
|
||||
"name": "task_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "worktree_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "base_commit",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"name": "merge_commit",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 5,
|
||||
"name": "executor_config",
|
||||
"type_info": "Jsonb"
|
||||
},
|
||||
{
|
||||
"ordinal": 6,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 7,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid",
|
||||
"Uuid",
|
||||
"Varchar",
|
||||
"Varchar",
|
||||
"Varchar",
|
||||
"Jsonb"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
true,
|
||||
true,
|
||||
true,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "7a9cb99ac1f3aa3926fa592c5261af9a3a8f56c2dba7195c6d733e7036c81019"
|
||||
}
|
||||
24
backend/.sqlx/query-84df316d94c83b9189ab76a41521bf6bc60ea6ae530f00cf544ac87c120f50c2.json
generated
Normal file
24
backend/.sqlx/query-84df316d94c83b9189ab76a41521bf6bc60ea6ae530f00cf544ac87c120f50c2.json
generated
Normal file
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT ta.id FROM task_attempts ta \n JOIN tasks t ON ta.task_id = t.id \n WHERE ta.id = $1 AND t.id = $2 AND t.project_id = $3",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid",
|
||||
"Uuid",
|
||||
"Uuid"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "84df316d94c83b9189ab76a41521bf6bc60ea6ae530f00cf544ac87c120f50c2"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "UPDATE projects SET name = $2, updated_at = $3 WHERE id = $1 RETURNING id, name, owner_id, created_at, updated_at",
|
||||
"query": "SELECT id, name, git_repo_path, owner_id, created_at, updated_at FROM projects WHERE git_repo_path = $1",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -15,25 +15,28 @@
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "git_repo_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "owner_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"ordinal": 4,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"ordinal": 5,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid",
|
||||
"Varchar",
|
||||
"Timestamptz"
|
||||
"Text"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
@@ -41,8 +44,9 @@
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "e6d8bb56195fb3c6a297c69bd69053cebfc486acd6368de53945adf31ffc707f"
|
||||
"hash": "9159bad45228f6ca30d0b50cc69259634ad9a5532bd3f288ec289f25498b3ce8"
|
||||
}
|
||||
71
backend/.sqlx/query-b7dcce1a1dca74bdebca528fbd03cd26293430587af27798c3297d95e06c99af.json
generated
Normal file
71
backend/.sqlx/query-b7dcce1a1dca74bdebca528fbd03cd26293430587af27798c3297d95e06c99af.json
generated
Normal file
@@ -0,0 +1,71 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at \n FROM tasks \n WHERE project_id = $1 \n ORDER BY created_at DESC",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 1,
|
||||
"name": "project_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "title",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "description",
|
||||
"type_info": "Text"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"name": "status!: TaskStatus",
|
||||
"type_info": {
|
||||
"Custom": {
|
||||
"name": "task_status",
|
||||
"kind": {
|
||||
"Enum": [
|
||||
"todo",
|
||||
"inprogress",
|
||||
"done",
|
||||
"cancelled",
|
||||
"inreview"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"ordinal": 5,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 6,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "b7dcce1a1dca74bdebca528fbd03cd26293430587af27798c3297d95e06c99af"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "INSERT INTO tasks (id, project_id, title, description, status, created_at, updated_at) \n VALUES ($1, $2, $3, $4, $5, $6, $7) \n RETURNING id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at",
|
||||
"query": "INSERT INTO tasks (id, project_id, title, description, status) \n VALUES ($1, $2, $3, $4, $5) \n RETURNING id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -71,9 +71,7 @@
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"Timestamptz",
|
||||
"Timestamptz"
|
||||
}
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
@@ -86,5 +84,5 @@
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "c293c87bbe20976357fd8fb433351ea8998828df6e1e30f7ae5f9984d0d05f8b"
|
||||
"hash": "c395009379487778ea43d0bdef7bd9d28f4755bcefb775ca036523aa88a4a3d8"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, name, owner_id, created_at, updated_at FROM projects WHERE id = $1",
|
||||
"query": "SELECT id, name, git_repo_path, owner_id, created_at, updated_at FROM projects WHERE id = $1",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -15,16 +15,21 @@
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "git_repo_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "owner_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"ordinal": 4,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"ordinal": 5,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
@@ -39,8 +44,9 @@
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "77d49aa68ae8cb1a44cb28582ebb7e817058b704a173ca6122e93a5eb829ff62"
|
||||
"hash": "cb377c76e9e7271d620e6e380fdf8b24da4ba3dcc7f481a884ad0a2746aea252"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "UPDATE tasks \n SET title = $3, description = $4, status = $5, updated_at = $6 \n WHERE id = $1 AND project_id = $2 \n RETURNING id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at",
|
||||
"query": "UPDATE tasks \n SET title = $3, description = $4, status = $5 \n WHERE id = $1 AND project_id = $2 \n RETURNING id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -71,8 +71,7 @@
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"Timestamptz"
|
||||
}
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
@@ -85,5 +84,5 @@
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "ce48496b80a462d440deb60661ac0a22b6ac18de38fcc772ef0f4fe2b44fa289"
|
||||
"hash": "ce7a3bd6c160c3eda73600590737c2082f9d772adefc5b32c784a337f4b49065"
|
||||
}
|
||||
71
backend/.sqlx/query-d2574d14252ead485e5db4e0eb84afa2fa3e12422f4e6ef6d623b768316e5ef4.json
generated
Normal file
71
backend/.sqlx/query-d2574d14252ead485e5db4e0eb84afa2fa3e12422f4e6ef6d623b768316e5ef4.json
generated
Normal file
@@ -0,0 +1,71 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "INSERT INTO task_attempt_activities (id, task_attempt_id, status, note) \n VALUES ($1, $2, $3, $4) \n RETURNING id, task_attempt_id, status as \"status!: TaskAttemptStatus\", note, created_at",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 1,
|
||||
"name": "task_attempt_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "status!: TaskAttemptStatus",
|
||||
"type_info": {
|
||||
"Custom": {
|
||||
"name": "task_attempt_status",
|
||||
"kind": {
|
||||
"Enum": [
|
||||
"init",
|
||||
"inprogress",
|
||||
"paused"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "note",
|
||||
"type_info": "Text"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid",
|
||||
"Uuid",
|
||||
{
|
||||
"Custom": {
|
||||
"name": "task_attempt_status",
|
||||
"kind": {
|
||||
"Enum": [
|
||||
"init",
|
||||
"inprogress",
|
||||
"paused"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"Text"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
true,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "d2574d14252ead485e5db4e0eb84afa2fa3e12422f4e6ef6d623b768316e5ef4"
|
||||
}
|
||||
57
backend/.sqlx/query-db4598a1164ee77414e789445f5da2384153bbade8ae677f60ea52d62875d23c.json
generated
Normal file
57
backend/.sqlx/query-db4598a1164ee77414e789445f5da2384153bbade8ae677f60ea52d62875d23c.json
generated
Normal file
@@ -0,0 +1,57 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, task_attempt_id, status as \"status!: TaskAttemptStatus\", note, created_at \n FROM task_attempt_activities \n WHERE task_attempt_id = $1 \n ORDER BY created_at DESC",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 1,
|
||||
"name": "task_attempt_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "status!: TaskAttemptStatus",
|
||||
"type_info": {
|
||||
"Custom": {
|
||||
"name": "task_attempt_status",
|
||||
"kind": {
|
||||
"Enum": [
|
||||
"init",
|
||||
"inprogress",
|
||||
"paused"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "note",
|
||||
"type_info": "Text"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
true,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "db4598a1164ee77414e789445f5da2384153bbade8ae677f60ea52d62875d23c"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, name, owner_id, created_at, updated_at FROM projects ORDER BY created_at DESC",
|
||||
"query": "SELECT id, name, git_repo_path, owner_id, created_at, updated_at FROM projects ORDER BY created_at DESC",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -15,16 +15,21 @@
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "git_repo_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "owner_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"ordinal": 4,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"ordinal": 5,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
@@ -37,8 +42,9 @@
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "fe9803c8acc05d6642190955801b86c73aef2e2d3ed3bf86d12a2ec2ee97f60c"
|
||||
"hash": "e7ec1292c5b93809f42eaf661779352efc8da4c52c1cb79811805240341bdf92"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at \n FROM tasks \n WHERE id = $1 AND project_id = $2",
|
||||
"query": "SELECT id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at \n FROM tasks \n WHERE id = $1 AND project_id = $2",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -68,5 +68,5 @@
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "d181fee1b69314810a3a9d4590a5f9e8df741ec19b58372c812137474b16891b"
|
||||
"hash": "f4d24cec6142ffb70bf1008235921035d310c452da78128420c93707485c0d7f"
|
||||
}
|
||||
55
backend/.sqlx/query-f5bfc8412c83b850fc0e686babfac68a358734a9dd9ff65fee96aa5f5b4d50d9.json
generated
Normal file
55
backend/.sqlx/query-f5bfc8412c83b850fc0e686babfac68a358734a9dd9ff65fee96aa5f5b4d50d9.json
generated
Normal file
@@ -0,0 +1,55 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "INSERT INTO projects (id, name, git_repo_path, owner_id) VALUES ($1, $2, $3, $4) RETURNING id, name, git_repo_path, owner_id, created_at, updated_at",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 1,
|
||||
"name": "name",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "git_repo_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "owner_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 5,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid",
|
||||
"Varchar",
|
||||
"Varchar",
|
||||
"Uuid"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "f5bfc8412c83b850fc0e686babfac68a358734a9dd9ff65fee96aa5f5b4d50d9"
|
||||
}
|
||||
33
backend/.sqlx/query-f72efcb41e92e03b8f8b988017d3b1c509322dc560742e9ef77fb9532b748fce.json
generated
Normal file
33
backend/.sqlx/query-f72efcb41e92e03b8f8b988017d3b1c509322dc560742e9ef77fb9532b748fce.json
generated
Normal file
@@ -0,0 +1,33 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT DISTINCT ta.id \n FROM task_attempts ta\n INNER JOIN (\n SELECT task_attempt_id, MAX(created_at) as latest_created_at\n FROM task_attempt_activities\n GROUP BY task_attempt_id\n ) latest_activity ON ta.id = latest_activity.task_attempt_id\n INNER JOIN task_attempt_activities taa ON ta.id = taa.task_attempt_id \n AND taa.created_at = latest_activity.latest_created_at\n WHERE taa.status = $1",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
{
|
||||
"Custom": {
|
||||
"name": "task_attempt_status",
|
||||
"kind": {
|
||||
"Enum": [
|
||||
"init",
|
||||
"inprogress",
|
||||
"paused"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "f72efcb41e92e03b8f8b988017d3b1c509322dc560742e9ef77fb9532b748fce"
|
||||
}
|
||||
28
backend/.sqlx/query-f7fd2f5022cbb587b5162b3444be71aa8337538356b8a278043b969b4375e576.json
generated
Normal file
28
backend/.sqlx/query-f7fd2f5022cbb587b5162b3444be71aa8337538356b8a278043b969b4375e576.json
generated
Normal file
@@ -0,0 +1,28 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "INSERT INTO task_attempt_activities (id, task_attempt_id, status, note) \n VALUES ($1, $2, $3, $4)",
|
||||
"describe": {
|
||||
"columns": [],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid",
|
||||
"Uuid",
|
||||
{
|
||||
"Custom": {
|
||||
"name": "task_attempt_status",
|
||||
"kind": {
|
||||
"Enum": [
|
||||
"init",
|
||||
"inprogress",
|
||||
"paused"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"Text"
|
||||
]
|
||||
},
|
||||
"nullable": []
|
||||
},
|
||||
"hash": "f7fd2f5022cbb587b5162b3444be71aa8337538356b8a278043b969b4375e576"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "INSERT INTO projects (id, name, owner_id, created_at, updated_at) VALUES ($1, $2, $3, $4, $5) RETURNING id, name, owner_id, created_at, updated_at",
|
||||
"query": "UPDATE projects SET name = $2, git_repo_path = $3 WHERE id = $1 RETURNING id, name, git_repo_path, owner_id, created_at, updated_at",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -15,16 +15,21 @@
|
||||
},
|
||||
{
|
||||
"ordinal": 2,
|
||||
"name": "git_repo_path",
|
||||
"type_info": "Varchar"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"name": "owner_id",
|
||||
"type_info": "Uuid"
|
||||
},
|
||||
{
|
||||
"ordinal": 3,
|
||||
"ordinal": 4,
|
||||
"name": "created_at",
|
||||
"type_info": "Timestamptz"
|
||||
},
|
||||
{
|
||||
"ordinal": 4,
|
||||
"ordinal": 5,
|
||||
"name": "updated_at",
|
||||
"type_info": "Timestamptz"
|
||||
}
|
||||
@@ -33,9 +38,7 @@
|
||||
"Left": [
|
||||
"Uuid",
|
||||
"Varchar",
|
||||
"Uuid",
|
||||
"Timestamptz",
|
||||
"Timestamptz"
|
||||
"Varchar"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
@@ -43,8 +46,9 @@
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "c9cb2594edb93c9cc75f0fc952c48fed263c536a1bf3b2e177e4a74cd3b4b30f"
|
||||
"hash": "f945f1d2ffb4458739c4e98c6dc35c215b5bc3ce1d59d5dd4948b032ab461cd9"
|
||||
}
|
||||
23
backend/.sqlx/query-fe4ce947b9df88ed2bc30f2a202d34b65d6f85c997fcc94ad35270d7492ed3a4.json
generated
Normal file
23
backend/.sqlx/query-fe4ce947b9df88ed2bc30f2a202d34b65d6f85c997fcc94ad35270d7492ed3a4.json
generated
Normal file
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id FROM tasks WHERE id = $1 AND project_id = $2",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
"ordinal": 0,
|
||||
"name": "id",
|
||||
"type_info": "Uuid"
|
||||
}
|
||||
],
|
||||
"parameters": {
|
||||
"Left": [
|
||||
"Uuid",
|
||||
"Uuid"
|
||||
]
|
||||
},
|
||||
"nullable": [
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "fe4ce947b9df88ed2bc30f2a202d34b65d6f85c997fcc94ad35270d7492ed3a4"
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"db_name": "PostgreSQL",
|
||||
"query": "SELECT id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at \n FROM tasks \n WHERE project_id = $1 \n ORDER BY created_at DESC",
|
||||
"query": "SELECT id, project_id, title, description, status as \"status!: TaskStatus\", created_at, updated_at \n FROM tasks \n WHERE id = $1",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
@@ -67,5 +67,5 @@
|
||||
false
|
||||
]
|
||||
},
|
||||
"hash": "2d134000c4bfb65ca088a1463146262e25ed053855e6cba5f72adc05d1ed9e85"
|
||||
"hash": "ff38912305d2082b153f12e0d59f0be12177a626b170b3ed3b41049b235cc57c"
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
-- Add stdout and stderr columns to task_attempts table
|
||||
ALTER TABLE task_attempts
|
||||
ADD COLUMN stdout TEXT,
|
||||
ADD COLUMN stderr TEXT;
|
||||
@@ -64,6 +64,8 @@ pub struct TaskAttempt {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
#[ts(skip)]
|
||||
pub executor_config: Option<serde_json::Value>, // JSON field for ExecutorConfig
|
||||
pub stdout: Option<String>,
|
||||
pub stderr: Option<String>,
|
||||
pub created_at: DateTime<Utc>,
|
||||
pub updated_at: DateTime<Utc>,
|
||||
}
|
||||
@@ -90,7 +92,7 @@ impl TaskAttempt {
|
||||
pub async fn find_by_id(pool: &PgPool, id: Uuid) -> Result<Option<Self>, sqlx::Error> {
|
||||
sqlx::query_as!(
|
||||
TaskAttempt,
|
||||
r#"SELECT id, task_id, worktree_path, base_commit, merge_commit, executor_config, created_at, updated_at
|
||||
r#"SELECT id, task_id, worktree_path, base_commit, merge_commit, executor_config, stdout, stderr, created_at, updated_at
|
||||
FROM task_attempts
|
||||
WHERE id = $1"#,
|
||||
id
|
||||
@@ -102,7 +104,7 @@ impl TaskAttempt {
|
||||
pub async fn find_by_task_id(pool: &PgPool, task_id: Uuid) -> Result<Vec<Self>, sqlx::Error> {
|
||||
sqlx::query_as!(
|
||||
TaskAttempt,
|
||||
r#"SELECT id, task_id, worktree_path, base_commit, merge_commit, executor_config, created_at, updated_at
|
||||
r#"SELECT id, task_id, worktree_path, base_commit, merge_commit, executor_config, stdout, stderr, created_at, updated_at
|
||||
FROM task_attempts
|
||||
WHERE task_id = $1
|
||||
ORDER BY created_at DESC"#,
|
||||
@@ -145,15 +147,17 @@ impl TaskAttempt {
|
||||
// Insert the record into the database
|
||||
let task_attempt = sqlx::query_as!(
|
||||
TaskAttempt,
|
||||
r#"INSERT INTO task_attempts (id, task_id, worktree_path, base_commit, merge_commit, executor_config)
|
||||
VALUES ($1, $2, $3, $4, $5, $6)
|
||||
RETURNING id, task_id, worktree_path, base_commit, merge_commit, executor_config, created_at, updated_at"#,
|
||||
r#"INSERT INTO task_attempts (id, task_id, worktree_path, base_commit, merge_commit, executor_config, stdout, stderr)
|
||||
VALUES ($1, $2, $3, $4, $5, $6, $7, $8)
|
||||
RETURNING id, task_id, worktree_path, base_commit, merge_commit, executor_config, stdout, stderr, created_at, updated_at"#,
|
||||
attempt_id,
|
||||
data.task_id,
|
||||
data.worktree_path,
|
||||
data.base_commit,
|
||||
data.merge_commit,
|
||||
executor_config_json
|
||||
executor_config_json,
|
||||
None::<String>, // stdout
|
||||
None::<String> // stderr
|
||||
)
|
||||
.fetch_one(pool)
|
||||
.await?;
|
||||
|
||||
@@ -21,7 +21,7 @@ export type UpdateTask = { title: string | null, description: string | null, sta
|
||||
|
||||
export type TaskAttemptStatus = "init" | "inprogress" | "paused";
|
||||
|
||||
export type TaskAttempt = { id: string, task_id: string, worktree_path: string, base_commit: string | null, merge_commit: string | null, created_at: string, updated_at: string, };
|
||||
export type TaskAttempt = { id: string, task_id: string, worktree_path: string, base_commit: string | null, merge_commit: string | null, stdout: string | null, stderr: string | null, created_at: string, updated_at: string, };
|
||||
|
||||
export type CreateTaskAttempt = { task_id: string, worktree_path: string, base_commit: string | null, merge_commit: string | null, executor_config: ExecutorConfig | null, };
|
||||
|
||||
|
||||
Reference in New Issue
Block a user