Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 17 additions & 5 deletions tyler/.claude/skills/notion/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,20 @@ operation: `publish`, `upload`, or `pull`.
`+notion search create fetch update attachment` and load what the
operation needs (search, fetch, create-pages, update-page,
create-attachment). Tool names vary by connector — match on the `notion`
prefix. If no Notion tools resolve and no `notion` CLI is on PATH, return
`NOTION UNAVAILABLE: <what was tried>` — the caller proceeds
GitHub + local only and says so.
prefix. If no Notion tools resolve and no `notion` CLI is on PATH, do
**not** silently degrade — how to proceed depends on whether a user is
present:
- **Interactive session** (a human invoked the calling skill): stop and
tell the user Notion isn't connected, give the connection path
(`claude mcp add --transport http notion https://mcp.notion.com/mcp`,
then `/mcp` to authenticate), and wait. Retry after they connect. Only
if they explicitly choose to skip, return `NOTION SKIPPED BY USER` —
the caller then runs its degraded mode so every artifact still ends up
reachable from the GitHub issue.
- **Headless run** (cron, cloud, no user to ask): return
`NOTION UNAVAILABLE: <what was tried>` and let the caller's degraded
mode carry the artifacts. Never block a headless run on a connection
prompt nobody can answer.
2. **Find the target database** — resolution order, most specific wins:
1. The project `CLAUDE.md`'s `Work-item tracking` section
(`notion_data_source`) — per-repo override only.
Expand All @@ -31,8 +42,9 @@ operation: `publish`, `upload`, or `pull`.
the match with the user, and offer to save it into this skill's
`config.yaml` so the search never repeats.

**Success criteria**: tools loaded and a data source resolved (or an explicit
`NOTION UNAVAILABLE`).
**Success criteria**: tools loaded and a data source resolved — or an explicit
`NOTION SKIPPED BY USER` (interactive) / `NOTION UNAVAILABLE` (headless);
never a silent fallback in an interactive session.

## Operation: publish (called by /create-feature, /create-epic, /create-issue)

Expand Down
15 changes: 12 additions & 3 deletions tyler/references/publish-work-item.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,15 @@ Used by `/create-feature`, `/create-epic`, and `/create-issue` after
4. Cross-link: add the Notion page URL to the GitHub issue body
(`gh issue edit`), and record both in `item.md` frontmatter as `github:`
and `notion:`.
5. On `NOTION UNAVAILABLE`, the issue must still carry everything a remote
`/do` needs — post each artifact as its own issue comment, wrapped in
5. Notion is not optional in an interactive session. If the notion skill
reports no connection, it blocks and helps the user connect (see its
setup step); the publish resumes at step 3 once connected. Degraded mode
below runs only on an explicit `NOTION SKIPPED BY USER`, or on
`NOTION UNAVAILABLE` from a headless run.
6. Degraded mode: the issue must carry everything a remote `/do` needs —
set the issue body to the **full `item.md` content** (not the summary),
record `notion: SKIPPED — re-run notion publish when connected` in the

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 Avoid using notion: for skipped publishes

When a user explicitly skips Notion, this writes a non-URL sentinel into the notion: frontmatter. Later /do wrap-up treats any notion: reference as a real Notion target (tyler/.claude/skills/do/SKILL.md lines 170-173) and invokes the notion upload operation with it, so degraded items can fail at wrap-up or try to upload plan/wrapup to SKIPPED — ... instead of simply skipping or re-publishing. Use a separate flag/status or update /do to recognize this sentinel before adding it to the canonical notion: field.

Useful? React with 👍 / 👎.

frontmatter, and post each artifact as its own issue comment, wrapped in
markers so Step 0 can harvest them back:

```
Expand All @@ -31,4 +38,6 @@ Used by `/create-feature`, `/create-epic`, and `/create-issue` after

Done when: the issue exists, every artifact is reachable from it (Notion
work item, or marker-delimited comments in degraded mode), and each of
issue / Notion page / item.md links to the others.
issue / Notion page / item.md links to the others. A publish that leaves
artifacts only on the local machine, or an issue that references a Notion
page that doesn't exist, is a failed publish — never that.