Skip to content

fix(cli): 1.33.1, --skill installs reported failure and were not tracked - #1503

Merged
davila7 merged 1 commit into
mainfrom
claude/project-thread-ofa5w0
Nov 10, 2026
Merged

davila7 merged 1 commit into
mainfrom
claude/project-thread-ofa5w0

Conversation

@davila7

@davila7 davila7 commented Nov 10, 2026 •

Copy link
Copy Markdown
Owner

Requested by Daniel · project thread

What this PR does

Fixes the 1.33.0 regression behind the drop in skill installs and the red prod smoke test since run 76 (2026-11-09 01:43 UTC).

#1467 replaced source: 'github_main' with a bare source in installIndividualSkill's trackDownload call (cli-tool/src/index.js:1536). The variable exists only in installIndividualMod. So every catalog skill install wrote all its files, then threw ReferenceError: source is not defined, which the catch reported as a network_error failure:

FAIL skill    development/skill-creator   Error installing skill: source is not defined
Installed 0 of 1 · 1 failed
Retry:  npx claude-code-templates@latest --skill development/skill-creator

trackDownload never ran, so no component_downloads row. GitHub rate limiting is not involved: SKILL.md (32,987 bytes) was downloaded in the failing smoke run. External skills (source.json) use a separate function and were not affected.

  • Restore source: 'github_main'.
  • cli-tool/tests/unit/skill-install.node-test.js: --skill against a stubbed GitHub; checks the files, the exec bit, true returned, and one trackDownload('skill', …, {source: 'github_main'}) + a success outcome. Fails on 1.33.0 with the same error.
  • .github/workflows/cli-ci.yml: the root npm test runs with no dependencies (version-sync.yml), so nothing loaded index.js before release. The new job runs npm ci, npm run test:install-paths and eslint@8.57.0 --rule no-undef over cli-tool/src + cli-tool/bin (browser-only analytics-web/ excluded). On 1.33.0 the lint flags exactly this line; on this branch it is clean.
  • Version 1.33.1 (not published), CHANGELOG. The 1.33.1 release also carries the cct binary removal (Remove the cct binary #1469), already on main.

Type

  • New component
  • Change to an existing component
  • CLI (cli-tool/src, cli-tool/bin)
  • Website (dashboard/)
  • Docs or other

How I tested it

  • Reproduced from the npm 1.33.0 tarball: --skill development/skill-creator → FAIL … source is not defined, files written.
  • npm pack of this branch, the smoke test's full batch (agent, command, mcp, hook, setting, skill, mod) against the real GitHub and aitmpl.com: Installed 7 of 7 · 0 failed, exit 0; skill-creator 17 files; no cct in bin/.
  • npm test (root) green; npm run test:install-paths passes on this branch and fails with the old line.

Release: needs npm publish from Daniel. Touches cli-tool/src, .github/ and package.json, so it merges by hand (no automerge).


Generated by Claude Code


Summary by cubic

Fixes the 1.33.0 regression in the CLI (cli-tool/) where every --skill install reported failure and was never download-tracked. A ReferenceError: source is not defined in installIndividualSkill's tracking call made the command write all files, then print FAIL, skip the component_downloads row, and exit 1 in a batch. External skills (source.json) used a separate function and were unaffected.

Bug Fixes

  • Restored source: 'github_main' in installIndividualSkill's trackDownload call; --skill installs now return true and are counted as success.
  • Added cli-tool/tests/unit/skill-install.node-test.js, a --skill install against a stubbed GitHub that asserts the files, exec bit, return value, and trackDownload payload; it fails on 1.33.0 with the same error.
  • Added .github/workflows/cli-ci.yml to run npm ci, npm run test:install-paths, and an eslint no-undef pass over cli-tool/src and cli-tool/bin on CLI PRs; the root npm test previously ran without dependencies.
  • No new components or environment variables were added; the catalog (docs/components.json) needs no regeneration.

Written for commit af73a28. Summary will update on new commits.

View guided diff Turn on auto-fix

1.33.0 (#1467) replaced `source: 'github_main'` with a bare `source` in
installIndividualSkill's trackDownload call, a variable that exists only in
installIndividualMod. Every catalog skill install wrote its files, then threw
"ReferenceError: source is not defined": the summary showed FAIL and a Retry
line, a batch exited 1, and the download was never sent to Supabase.
External skills (source.json) were not affected.

- Restore source: 'github_main'
- skill-install.node-test.js: --skill against a stubbed GitHub, asserting the
  files, the return value and the trackDownload call (fails on 1.33.0)
- cli-ci.yml: npm ci + that test + an eslint no-undef pass over cli-tool/src
  and cli-tool/bin on CLI PRs (root npm test runs without dependencies)
- Version 1.33.1 (not published), CHANGELOG

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012PXzcbUeN566p89EuSse2f
@davila7 davila7 self-assigned this Nov 10, 2026

davila7 commented Nov 10, 2026

Copy link
Copy Markdown
Owner Author

All checks green fails on purpose here: this PR touches MANUAL_PATHS (cli-tool/src/, .github/, package.json), and the gate prints "Touches paths that need a human: merge by hand." It is not a code failure, and this PR can't fix it. The PR has to be merged by hand.


Generated by Claude Code

@davila7
davila7 marked this pull request as ready for review November 10, 2026 03:09
@davila7
davila7 merged commit c9bbebe into main Nov 10, 2026
8 of 10 checks passed
@davila7
davila7 deleted the claude/project-thread-ofa5w0 branch November 10, 2026 03:09
@greptile-apps

greptile-apps Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The PR affects catalog skill installs and checks on CLI changes.

The fix appears safe to merge; expanding the workflow filters is a non-blocking improvement.

Findings

  1. P2 CLI dependency changes skip checks ▶

Summary

Restores successful catalog skill installs by replacing the undefined source variable with 'github_main'.

  • --skill installs finish successfully and get tracked.
  • CLI changes trigger focused install and identifier checks.

Reviews (1) · Last reviewed commit: "fix(cli): 1.33.1, --skill installs repor..." · Reviewed by Greptile

Comment on lines +15 to +16
- 'cli-tool/tests/**'
- 'package.json'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P2 CLI dependency changes skip checks

The new workflow skips PRs that change only cli-tool/package.json or cli-tool/package-lock.json. Those files define the CLI's own dependencies and release scripts, so dependency-only CLI changes miss this check. Add both files to the PR path filters so those changes receive the new checks too.

Suggested change
- 'cli-tool/tests/**'
- 'package.json'
- 'cli-tool/tests/**'
- 'cli-tool/package.json'
- 'cli-tool/package-lock.json'
- 'package.json'

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.

2 participants