@hasna/todos 0.13.5 → 0.13.6

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.
@@ -1 +1 @@
1
- {"version":3,"file":"task-crud.d.ts","sourceRoot":"","sources":["../../../src/mcp/tools/task-crud.ts"],"names":[],"mappings":"AACA;;;GAGG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAejD,UAAU,eAAe;IACvB,kBAAkB,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC;IAC9C,SAAS,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC;IACzD,WAAW,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,MAAM,CAAC;IACxC,UAAU,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,MAAM,CAAC;IACnC,gBAAgB,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,mBAAmB,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC;IACvE,aAAa,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,UAAU,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,SAAS,CAAC;CAC3F;AAED,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,SAAS,EAAE,GAAG,EAAE,eAAe,QAkW5E"}
1
+ {"version":3,"file":"task-crud.d.ts","sourceRoot":"","sources":["../../../src/mcp/tools/task-crud.ts"],"names":[],"mappings":"AACA;;;GAGG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAgBjD,UAAU,eAAe;IACvB,kBAAkB,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC;IAC9C,SAAS,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC;IACzD,WAAW,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,MAAM,CAAC;IACxC,UAAU,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,MAAM,CAAC;IACnC,gBAAgB,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,mBAAmB,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC;IACvE,aAAa,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,UAAU,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,SAAS,CAAC;CAC3F;AAED,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,SAAS,EAAE,GAAG,EAAE,eAAe,QAkX5E"}
package/dist/mcp.js CHANGED
@@ -41,7 +41,7 @@ var __require = import.meta.require;
41
41
  // package.json
42
42
  var package_default = {
43
43
  name: "@hasna/todos",
44
- version: "0.13.5",
44
+ version: "0.13.6",
45
45
  description: "Universal task management for AI coding agents - CLI + MCP server + interactive TUI",
46
46
  type: "module",
47
47
  main: "dist/index.js",
package/dist/registry.js CHANGED
@@ -2331,6 +2331,7 @@ function ensureSchema(db) {
2331
2331
  ensureColumn("tasks", "reason", "TEXT");
2332
2332
  ensureColumn("tasks", "spawned_from_session", "TEXT");
2333
2333
  ensureColumn("tasks", "assigned_by", "TEXT");
2334
+ ensureColumn("tasks", "created_by", "TEXT");
2334
2335
  ensureColumn("tasks", "assigned_from_project", "TEXT");
2335
2336
  ensureColumn("tasks", "started_at", "TEXT");
2336
2337
  ensureColumn("tasks", "task_type", "TEXT");
@@ -2493,6 +2494,8 @@ function ensureSchema(db) {
2493
2494
  ensureIndex("CREATE INDEX IF NOT EXISTS idx_project_sources_project ON project_sources(project_id)");
2494
2495
  ensureIndex("CREATE INDEX IF NOT EXISTS idx_project_sources_type ON project_sources(type)");
2495
2496
  ensureIndex("CREATE INDEX IF NOT EXISTS idx_tasks_assigned_by ON tasks(assigned_by)");
2497
+ ensureIndex("CREATE INDEX IF NOT EXISTS idx_tasks_created_by ON tasks(created_by)");
2498
+ ensureIndex("CREATE INDEX IF NOT EXISTS idx_tasks_assigned_created ON tasks(assigned_to, created_by)");
2496
2499
  ensureIndex("CREATE INDEX IF NOT EXISTS idx_task_rel_source ON task_relationships(source_task_id)");
2497
2500
  ensureIndex("CREATE INDEX IF NOT EXISTS idx_task_rel_target ON task_relationships(target_task_id)");
2498
2501
  ensureIndex("CREATE INDEX IF NOT EXISTS idx_task_rel_type ON task_relationships(relationship_type)");
@@ -8792,13 +8795,14 @@ function createTask(input, db) {
8792
8795
  const timestamp2 = now();
8793
8796
  const tags = input.tags || [];
8794
8797
  const machineId = currentStorageMachineId(d);
8798
+ const createdBy = input.created_by || input.agent_id || null;
8795
8799
  const assignedBy = input.assigned_by || input.agent_id;
8796
8800
  const assignedFromProject = input.assigned_from_project || null;
8797
8801
  let id = uuid();
8798
8802
  for (let attempt = 0;attempt < 3; attempt++) {
8799
8803
  try {
8800
- d.run(`INSERT INTO tasks (id, short_id, project_id, parent_id, plan_id, task_list_id, cycle_id, title, description, status, priority, agent_id, assigned_to, session_id, working_dir, tags, metadata, version, created_at, updated_at, due_at, estimated_minutes, sla_minutes, confidence, retry_count, max_retries, retry_after, requires_approval, approved_by, approved_at, recurrence_rule, recurrence_parent_id, spawns_template_id, reason, spawned_from_session, assigned_by, assigned_from_project, task_type, machine_id)
8801
- VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, 1, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`, [
8804
+ d.run(`INSERT INTO tasks (id, short_id, project_id, parent_id, plan_id, task_list_id, cycle_id, title, description, status, priority, agent_id, assigned_to, session_id, working_dir, tags, metadata, version, created_at, updated_at, due_at, estimated_minutes, sla_minutes, confidence, retry_count, max_retries, retry_after, requires_approval, approved_by, approved_at, recurrence_rule, recurrence_parent_id, spawns_template_id, reason, spawned_from_session, assigned_by, created_by, assigned_from_project, task_type, machine_id)
8805
+ VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, 1, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`, [
8802
8806
  id,
8803
8807
  null,
8804
8808
  input.project_id || null,
@@ -8834,6 +8838,7 @@ function createTask(input, db) {
8834
8838
  input.reason || null,
8835
8839
  input.spawned_from_session || null,
8836
8840
  assignedBy || null,
8841
+ createdBy,
8837
8842
  assignedFromProject || null,
8838
8843
  input.task_type || null,
8839
8844
  machineId
@@ -8943,6 +8948,14 @@ function listTasks(filter = {}, db) {
8943
8948
  conditions.push("agent_id = ?");
8944
8949
  params.push(filter.agent_id);
8945
8950
  }
8951
+ if (filter.created_by) {
8952
+ conditions.push("LOWER(created_by) = LOWER(?)");
8953
+ params.push(filter.created_by);
8954
+ }
8955
+ if (filter.not_created_by) {
8956
+ conditions.push("(created_by IS NULL OR LOWER(created_by) != LOWER(?))");
8957
+ params.push(filter.not_created_by);
8958
+ }
8946
8959
  if (filter.session_id) {
8947
8960
  conditions.push("session_id = ?");
8948
8961
  params.push(filter.session_id);
@@ -9096,6 +9109,14 @@ function countTasks(filter = {}, db) {
9096
9109
  conditions.push("agent_id = ?");
9097
9110
  params.push(filter.agent_id);
9098
9111
  }
9112
+ if (filter.created_by) {
9113
+ conditions.push("LOWER(created_by) = LOWER(?)");
9114
+ params.push(filter.created_by);
9115
+ }
9116
+ if (filter.not_created_by) {
9117
+ conditions.push("(created_by IS NULL OR LOWER(created_by) != LOWER(?))");
9118
+ params.push(filter.not_created_by);
9119
+ }
9099
9120
  if (filter.session_id) {
9100
9121
  conditions.push("session_id = ?");
9101
9122
  params.push(filter.session_id);
@@ -11900,7 +11921,7 @@ var init_tasks = __esm(() => {
11900
11921
  // package.json
11901
11922
  var package_default = {
11902
11923
  name: "@hasna/todos",
11903
- version: "0.13.5",
11924
+ version: "0.13.6",
11904
11925
  description: "Universal task management for AI coding agents - CLI + MCP server + interactive TUI",
11905
11926
  type: "module",
11906
11927
  main: "dist/index.js",
@@ -15332,6 +15353,7 @@ function task(input) {
15332
15353
  reason: "Bundled deterministic onboarding fixture",
15333
15354
  spawned_from_session: null,
15334
15355
  assigned_by: null,
15356
+ created_by: null,
15335
15357
  assigned_from_project: null,
15336
15358
  task_type: "onboarding",
15337
15359
  cost_tokens: 0,
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "packageName": "@hasna/todos",
3
- "packageVersion": "0.13.5",
3
+ "packageVersion": "0.13.6",
4
4
  "repository": "https://github.com/hasna/todos.git",
5
- "gitCommit": "305b1033309bc22e62d2a636499436f43f01fff3",
6
- "gitTree": "e291ed0071837371f5711a02455d6155c42ec7a5",
7
- "sourceTreeSha256": "0ad301aa18686673cba69326bacd3aeacbcb92096d6f10b5477e500d6883c467",
8
- "generatedAt": "2026-07-31T15:55:50.000Z"
5
+ "gitCommit": "09d027479c9f465d4931c875aeb44568ece8f9d4",
6
+ "gitTree": "e4c2e7dd33920073e437958d307317977ee96fb8",
7
+ "sourceTreeSha256": "706786c94a71e20a3163a2f9d4c7605a265250c3eb1d131e44cc4c58d3d51918",
8
+ "generatedAt": "2026-07-31T17:04:55.000Z"
9
9
  }