Skip to content

Composer: $task makes a task and starts a chat for it - #69

Merged
ehonis merged 1 commit into
mainfrom
sync/private-main
Nov 25, 2026
Merged

ehonis merged 1 commit into
mainfrom
sync/private-main

Conversation

@ehonis

@ehonis ehonis commented Nov 25, 2026

Copy link
Copy Markdown
Owner

Published from the private repository by oss-sync.

  • Composer: $task makes a task and starts a chat for it

13 files changed, 365 insertions(+), 25 deletions(-)

Published from the private repository by oss-sync.

- Composer: $task makes a task and starts a chat for it

 13 files changed, 365 insertions(+), 25 deletions(-)
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 25, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-25T13:37:16.085082Z 3676419 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@ehonis
ehonis merged commit 5c5b336 into main Nov 25, 2026
4 checks passed
@ehonis
ehonis deleted the sync/private-main branch November 25, 2026 13:33

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3676419741

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

const key = draftKey
const task = await createTask(fields, fields.folderId)
if (!task) return false
drafts.write(key, { text: '' }, at)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve edits made while task creation is pending

When task creation is slow, the editor remains writable and Escape can switch it back to message mode, so the owner can enter new text before the request completes. If they remain on the same draft, this unconditional write then erases those newer words and moves the now-empty draft to the task; only changing draft keys avoids the loss. Capture and compare the submitted text or lock/cancel edits until creation settles.

AGENTS.md reference: AGENTS.md:L426-L426

Useful? React with 👍 / 👎.

Comment thread web/src/chat/newTask.ts

export function readNewTask(value: string, opts: { now: Date; folders: readonly FolderName[]; ignore: readonly string[]; projectId: string | null }): { parsed: QuickAdd; fields: NewTaskFields | null } {
const parsed = parseQuickAdd(taskLine(value), { now: opts.now, folders: opts.folders, ignore: opts.ignore })
const title = parsed.title.slice(0, 500).trim()

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Do not silently truncate long task titles

For a title longer than 500 characters, such as pasted text, the composer continues to display the complete task line but only this truncated value is submitted; after successful creation the remaining text disappears from the composer, so the saved task silently loses its tail. The Tasks quick-add input instead enforces its 500-character limit while typing, so this path should likewise prevent excess input, report it, or preserve the unsaved remainder.

Useful? React with 👍 / 👎.

Comment thread web/src/chat/Composer.tsx
Comment on lines +583 to +585
const task = useMemo(() => (inTask
? readNewTask(value, { now: new Date(), folders: folderNames(projects), ignore: taskIgnore, projectId: destinations?.projectId ?? null })
: null), [inTask, value, projects, taskIgnore, destinations?.projectId])

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Recompute relative due dates when the local day changes

If a $task line containing a relative date such as today or tomorrow is left open across midnight, this memo retains the Date from the last text or project change. Pressing Enter afterward submits the previous day's computed dueDate, whereas the Tasks page refreshes its now value every minute. Include a local-day key in the dependencies or parse again at submission time.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant