@hasna/todos 0.15.46 → 0.15.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dashboard/dist/assets/index-BNQ4gJua.js +342 -0
- package/dashboard/dist/assets/index-DjzvHUWt.css +1 -0
- package/dashboard/dist/index.html +2 -2
- package/dist/cli/commands/query-commands.d.ts.map +1 -1
- package/dist/cli/components/Dashboard.d.ts +1 -1
- package/dist/cli/components/Dashboard.d.ts.map +1 -1
- package/dist/cli/components/Header.d.ts +1 -1
- package/dist/cli/components/Header.d.ts.map +1 -1
- package/dist/cli/components/ProjectList.d.ts +1 -1
- package/dist/cli/components/ProjectList.d.ts.map +1 -1
- package/dist/cli/components/SearchView.d.ts +1 -1
- package/dist/cli/components/SearchView.d.ts.map +1 -1
- package/dist/cli/components/TaskDetail.d.ts +1 -1
- package/dist/cli/components/TaskDetail.d.ts.map +1 -1
- package/dist/cli/components/TaskForm.d.ts +1 -1
- package/dist/cli/components/TaskForm.d.ts.map +1 -1
- package/dist/cli/components/TaskList.d.ts +1 -1
- package/dist/cli/components/TaskList.d.ts.map +1 -1
- package/dist/cli/index.js +671 -155
- package/dist/contracts.js +396 -82
- package/dist/db/task-crud.d.ts +6 -0
- package/dist/db/task-crud.d.ts.map +1 -1
- package/dist/db/tasks.d.ts +1 -1
- package/dist/db/tasks.d.ts.map +1 -1
- package/dist/db/webhooks.d.ts.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +561 -143
- package/dist/lib/dedupe-projection.d.ts +48 -0
- package/dist/lib/dedupe-projection.d.ts.map +1 -0
- package/dist/lib/redaction.d.ts.map +1 -1
- package/dist/lib/task-dedupe.d.ts +5 -9
- package/dist/lib/task-dedupe.d.ts.map +1 -1
- package/dist/mcp/index.js +621 -154
- package/dist/mcp/tools/task-crud.d.ts.map +1 -1
- package/dist/mcp.js +6 -4
- package/dist/project-registration.js +502 -141
- package/dist/registry.js +396 -82
- package/dist/release-provenance.json +5 -5
- package/dist/server/cloud.d.ts.map +1 -1
- package/dist/server/index.js +1278 -342
- package/dist/server/routes.d.ts.map +1 -1
- package/dist/server/v1.d.ts.map +1 -1
- package/dist/storage/postgres-adapter.d.ts.map +1 -1
- package/dist/storage/postgres-errors.d.ts +15 -0
- package/dist/storage/postgres-errors.d.ts.map +1 -0
- package/dist/storage/postgres-sync.d.ts +7 -0
- package/dist/storage/postgres-sync.d.ts.map +1 -1
- package/dist/storage/shadow-outbox.d.ts.map +1 -1
- package/dist/storage/shadow.d.ts.map +1 -1
- package/dist/storage.js +510 -137
- package/dist/task-manifest.js +118 -47
- package/dist/task-subtree-transfer.js +326 -44
- package/dist/types/index.d.ts +2 -2
- package/dist/types/index.d.ts.map +1 -1
- package/package.json +6 -4
- package/dashboard/dist/assets/index-DJm6m6Yy.css +0 -1
- package/dashboard/dist/assets/index-DVotjwab.js +0 -346
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import type { Task, TaskPriority, TaskStatus } from "../types/index.js";
|
|
2
|
+
/**
|
|
3
|
+
* The ONLY metadata keys the dedup projection carries. This is exactly the
|
|
4
|
+
* source-key set the fingerprint in `task-dedupe.ts` consumes
|
|
5
|
+
* (`sourceKeysFor`). Any other metadata — free-form `token`, `api_key`,
|
|
6
|
+
* `secret`, arbitrary composites — is never projected, so a credential value
|
|
7
|
+
* sitting in free-form metadata can never reach a dedup workflow's capture.
|
|
8
|
+
*
|
|
9
|
+
* Regression O15-00170 (incidents 713001/713022/713043-46/713119): workflows
|
|
10
|
+
* doing deduplication captured credential-bearing whole-task composites from
|
|
11
|
+
* `todos list --json` / `--format compact` / `--format csv` because no
|
|
12
|
+
* package-owned bounded projection existed. This allowlist is the bounded
|
|
13
|
+
* surface that abstraction provides.
|
|
14
|
+
*/
|
|
15
|
+
export declare const DEDUPE_SOURCE_KEY_ALLOWLIST: readonly ["github_url", "github_issue_url", "github_pr_url", "source_url", "url", "external_url", "issue_url", "github_owner", "github_repo", "github_number"];
|
|
16
|
+
/**
|
|
17
|
+
* A task reduced to exactly the fields the dedup fingerprint consumes, plus a
|
|
18
|
+
* bounded source-key metadata object. It deliberately excludes free-form
|
|
19
|
+
* `metadata`, `tags`, comments, run/plan fields, and every other composite
|
|
20
|
+
* field of `Task` — the surfaces where credential values leaked. The carried
|
|
21
|
+
* free-form text (`title`, `description`) is redacted through the same
|
|
22
|
+
* pattern redactor every other output surface uses, so a credential embedded
|
|
23
|
+
* in prose never survives into the projection.
|
|
24
|
+
*/
|
|
25
|
+
export interface DedupeTaskProjection {
|
|
26
|
+
id: string;
|
|
27
|
+
short_id: string | null;
|
|
28
|
+
title: string;
|
|
29
|
+
description: string | null;
|
|
30
|
+
status: TaskStatus;
|
|
31
|
+
created_at: string;
|
|
32
|
+
updated_at: string;
|
|
33
|
+
project_id: string | null;
|
|
34
|
+
task_list_id: string | null;
|
|
35
|
+
assigned_to: string | null;
|
|
36
|
+
priority: TaskPriority;
|
|
37
|
+
metadata: Record<string, unknown>;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Project whole tasks into the bounded dedup shape.
|
|
41
|
+
*
|
|
42
|
+
* This is the package-owned "canonical-machine" abstraction: the only way a
|
|
43
|
+
* dedup workflow may capture task state for deduplication. It never emits a
|
|
44
|
+
* whole-task composite, so a credential that lives in free-form metadata,
|
|
45
|
+
* tags, or a nested composite cannot be captured with it.
|
|
46
|
+
*/
|
|
47
|
+
export declare function projectTasksForDedupe(tasks: Task[]): DedupeTaskProjection[];
|
|
48
|
+
//# sourceMappingURL=dedupe-projection.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dedupe-projection.d.ts","sourceRoot":"","sources":["../../src/lib/dedupe-projection.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAGxE;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,2BAA2B,gKAW9B,CAAC;AAEX;;;;;;;;GAQG;AACH,MAAM,WAAW,oBAAoB;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,MAAM,EAAE,UAAU,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,QAAQ,EAAE,YAAY,CAAC;IACvB,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACnC;AAED;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,IAAI,EAAE,GAAG,oBAAoB,EAAE,CAyB3E"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"redaction.d.ts","sourceRoot":"","sources":["../../src/lib/redaction.ts"],"names":[],"mappings":"AAAA,OAAO,EAA0B,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAE9E,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;CACf;
|
|
1
|
+
{"version":3,"file":"redaction.d.ts","sourceRoot":"","sources":["../../src/lib/redaction.ts"],"names":[],"mappings":"AAAA,OAAO,EAA0B,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAE9E,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;CACf;AAqGD,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAUxD;AAED,wBAAgB,WAAW,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,CAe1C;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,aAAa,EAAE,CAOjE;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAExD;AAED,wBAAgB,qBAAqB,IAAI,kBAAkB,CAK1D;AAED,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,kBAAkB,GAAG,kBAAkB,CAQtF"}
|
|
@@ -1,23 +1,19 @@
|
|
|
1
1
|
import type { Database } from "bun:sqlite";
|
|
2
2
|
import type { Task } from "../types/index.js";
|
|
3
|
+
import { type DedupeTaskProjection } from "./dedupe-projection.js";
|
|
3
4
|
export interface FindDuplicateTasksOptions {
|
|
4
5
|
threshold?: number;
|
|
5
6
|
limit?: number;
|
|
6
7
|
include_archived?: boolean;
|
|
7
8
|
}
|
|
8
|
-
export interface TaskDuplicateProbe {
|
|
9
|
-
title: string;
|
|
10
|
-
description?: string | null;
|
|
11
|
-
metadata?: Record<string, unknown>;
|
|
12
|
-
}
|
|
13
9
|
export interface TaskDuplicateMatch {
|
|
14
|
-
task:
|
|
10
|
+
task: DedupeTaskProjection;
|
|
15
11
|
score: number;
|
|
16
12
|
reasons: string[];
|
|
17
13
|
}
|
|
18
14
|
export interface DuplicateTaskCandidate {
|
|
19
|
-
primary_task:
|
|
20
|
-
duplicate_task:
|
|
15
|
+
primary_task: DedupeTaskProjection;
|
|
16
|
+
duplicate_task: DedupeTaskProjection;
|
|
21
17
|
score: number;
|
|
22
18
|
reasons: string[];
|
|
23
19
|
}
|
|
@@ -55,7 +51,7 @@ export declare function findDuplicateTasks(options?: FindDuplicateTasksOptions,
|
|
|
55
51
|
* Score a prospective task against local tasks without inserting a temporary
|
|
56
52
|
* row. Producer previews use this to report likely duplicates before apply.
|
|
57
53
|
*/
|
|
58
|
-
export declare function findDuplicateTasksForInput(input:
|
|
54
|
+
export declare function findDuplicateTasksForInput(input: DedupeTaskProjection, options?: FindDuplicateTasksOptions, db?: Database): TaskDuplicateMatch[];
|
|
59
55
|
export declare function mergeDuplicateTask(input: MergeDuplicateTaskInput, db?: Database): TaskMergeResult;
|
|
60
56
|
export declare const findDuplicateCandidates: typeof findDuplicateTasks;
|
|
61
57
|
//# sourceMappingURL=task-dedupe.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"task-dedupe.d.ts","sourceRoot":"","sources":["../../src/lib/task-dedupe.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAC3C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"task-dedupe.d.ts","sourceRoot":"","sources":["../../src/lib/task-dedupe.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAC3C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAK9C,OAAO,EAAyB,KAAK,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAE1F,MAAM,WAAW,yBAAyB;IACxC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B;AAED,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,oBAAoB,CAAC;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,MAAM,WAAW,sBAAsB;IACrC,YAAY,EAAE,oBAAoB,CAAC;IACnC,cAAc,EAAE,oBAAoB,CAAC;IACrC,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,MAAM,WAAW,uBAAuB;IACtC,eAAe,EAAE,MAAM,CAAC;IACxB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,EAAE,MAAM,CAAC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