Add issue identifiers, activity run tracking, and migration inspection
Add issuePrefix/issueCounter to companies and issueNumber/identifier to issues for human-readable issue IDs (e.g. PAP-42). Add runId to activity_log for linking activity to heartbeat runs. Rework DB client to support migration state inspection and interactive pending migration prompts at startup. Add reopen option to issue comments validator. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -7,6 +7,7 @@ export interface ActivityEvent {
|
||||
entityType: string;
|
||||
entityId: string;
|
||||
agentId: string | null;
|
||||
runId: string | null;
|
||||
details: Record<string, unknown> | null;
|
||||
createdAt: Date;
|
||||
}
|
||||
|
||||
@@ -5,8 +5,11 @@ export interface Company {
|
||||
name: string;
|
||||
description: string | null;
|
||||
status: CompanyStatus;
|
||||
issuePrefix: string;
|
||||
issueCounter: number;
|
||||
budgetMonthlyCents: number;
|
||||
spentMonthlyCents: number;
|
||||
requireBoardApprovalForNewAgents: boolean;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
}
|
||||
|
||||
@@ -25,6 +25,8 @@ export interface Issue {
|
||||
assigneeAgentId: string | null;
|
||||
createdByAgentId: string | null;
|
||||
createdByUserId: string | null;
|
||||
issueNumber: number | null;
|
||||
identifier: string | null;
|
||||
requestDepth: number;
|
||||
billingCode: string | null;
|
||||
startedAt: Date | null;
|
||||
|
||||
@@ -31,6 +31,7 @@ export type CheckoutIssue = z.infer<typeof checkoutIssueSchema>;
|
||||
|
||||
export const addIssueCommentSchema = z.object({
|
||||
body: z.string().min(1),
|
||||
reopen: z.boolean().optional(),
|
||||
});
|
||||
|
||||
export type AddIssueComment = z.infer<typeof addIssueCommentSchema>;
|
||||
|
||||
Reference in New Issue
Block a user