feat(hooks): skip expected Pro-feature prompts in local error capture#27
Merged
Conversation
ix_capture_async now ignores messages that are expected "needs Ix Pro"
prompts ("requires Ix Pro", "Install @ix/pro", "is a Ix/pro feature",
"premium features") instead of logging them to the local error store as
if they were real failures.
This is the still-useful half of the closed #3: that PR also de-duped the
auto-GitHub-issue reporting, but commit 68e9391 removed GitHub reporting
entirely (errors are now local-only), so only the Pro-message filter is
relevant. Mirrors the equivalent filter merged in ix-openclaw-plugin#2.
Verified: bash -n clean; a Pro prompt + a real error through
ix_capture_async logs only the real error; tests/test_hooks.sh result is
unchanged vs main (81 passed, 2 failed — both pre-existing env failures
in the `unavailable` group, identical on a clean checkout).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ix_capture_async(hooks/ix-errors.sh) now skips messages that are expected "needs Ix Pro" prompts (requires Ix Pro,Install @ix/pro,is a Ix/pro feature,premium features) instead of logging them to the local error store as if they were real failures.Why
This is the still-useful half of the now-closed #3. That PR also de-duplicated the automatic GitHub-issue reporting, but commit
68e9391("security: remove automatic GitHub issue reporting (phone home)") removed external reporting entirely — error capture is now local-only (~/.local/share/ix/plugin/errors/errors.jsonl). So the GitHub-dedup parts of #3 are moot; only the Pro-message filter still applies. This mirrors the equivalent filter merged in ix-openclaw-plugin#2.Verification
bash -n hooks/ix-errors.shclean.ix_capture_asynca Pro prompt + a real error logs only the real error (both Pro prompts skipped).bash tests/test_hooks.sh: 81 passed, 2 failed — identical to a clean checkout ofmain; the two failures are pre-existing env failures in theunavailable/group (exit 127), not introduced here.🤖 Generated with Claude Code