fix(dog-intelligence): hygiene items #2, #4, #5 from issue #598#599
Open
arc0btc wants to merge 7 commits into
Open
fix(dog-intelligence): hygiene items #2, #4, #5 from issue #598#599arc0btc wants to merge 7 commits into
arc0btc wants to merge 7 commits into
Conversation
On-chain intelligence hub for DOG•GO•TO•THE•MOON rune powered by DOG DATA's Bitcoin Core + Ord full node. 5 sub-commands: pulse, whales (>1M DOG threshold), diamond, airdrop, lth-sth. Read-only, no chain writes, zero dependencies. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Remove unused variable in catch block - Fix misleading comment: 1B → 1M DOG in whales() - Author: LimaDevBTC (operator) + Xored Pike (AIBTC agent) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
… bitcoin) Registry compliance fixes (all requested by reviewers): - SKILL.md: migrate frontmatter to nested metadata: block - SKILL.md: fix author_agent -> author-agent (hyphen), user-invocable as string - SKILL.md: fix requires and tags from array to comma-separated string - SKILL.md: add missing Output contract section - AGENT.md: add required YAML frontmatter (name, skill, description) Skill improvements: - whales: migrate to /whale-alerts (multi-chain, severity CRITICAL/HIGH, USD value) - whales: use /dog-rune/top-holders dedicated endpoint - pulse: use /markets for aggregated price across all exchanges - doctor: smoke-test new endpoints (markets, whale-alerts, multichain) - New action: markets — 20+ exchanges with volume, spread, trust score - New action: multichain — DOG on Stacks + Solana (bridged supply) - New action: bitcoin — BTC network status, mempool, fees, difficulty Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…blockers - Migrate main() from manual Bun.argv switch to Commander.js (rule CLI_USES_COMMANDER + CLI_HAS_DOCTOR_SUBCOMMAND — BLOCKS MERGE) - Add skills/dog-intelligence/package.json with commander ^12.1.0 dep - Drop requires: "settings" from SKILL.md — skill doesn't exist on aibtcdev/skills:main or BitflowFinance/bff-skills:main (BLOCKS MERGE) - Drop tag "multichain" from SKILL.md — not in allowed values list (FRONTMATTER_TAGS_VALID_VALUES — BLOCKS MERGE on strict checks) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Addresses arc0btc 2026-05-08 review:
1. Truthy-null traps: replace `x ? +x.toFixed(N) : null` with a `num()` helper
that uses `typeof x === "number" && Number.isFinite(x)` so legitimate 0
values are preserved instead of being silently coerced to null.
Affected: lth_pct, sth_pct, change_24h, gini, top_10/100/1000, in_profit,
in_loss, retention/accumulator/dumper rates, hashrate_eh_s, difficulty,
progress_pct, estimated_change_pct, price_spread_pct, price_change_24h,
median_age_days, avg_age_days, total_market_cap_usd, total_volume_24h_usd,
liquidity_usd, market_cap_usd, volume_24h_usd.
2. bitcoin handler: emit `status: "blocked"` on HTTP 429 (matching the other
7 actions) so agents running backoff logic detect rate limits consistently.
3. hodl_waves: store numeric percentages (`+(...).toFixed(2)`) instead of
string suffixes ("12.34%"), aligning with every other percentage field.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…, BitflowFinance#5 from issue BitflowFinance#598 - get() catch now captures err and returns message string so timeout vs DNS vs TLS errors are distinguishable in the response payload - rate_limited out() calls now include retry_after_seconds as a top-level numeric field (fetchMultiple and bitcoin action handlers) - totalSupply constant in whales() gets a comment explaining the fixed etching supply (rune 840000:3 cannot mint)
✅ Validation PassedSkill: All checks passed. This submission is ready for review. |
This was referenced May 8, 2026
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.
Closes items #2, #4, #5 from #598. Depends on #14 (targets same file — rebase or merge after #14 lands).
Changes
Item #5 —
get()catch preserves error classBefore:
catch { return { ..., data: null } }swallowed the underlying error, making timeout vs DNS vs TLS failures indistinguishable.After:
catch (err) { return { ..., data: err instanceof Error ? err.message : String(err) } }— error message surfaced in response payload.Item #4 — structured
retry_after_secondsin rate-limit responsesBefore: retry info was only in the prose error string (
"Rate limited on /endpoint. Retry after 60s."), requiring regex to parse.After:
retry_after_secondsadded as a top-level numeric field in thedataobject on bothfetchMultipleand thebitcoin()direct-call handler.Item #2 — comment on
totalSupplyconstantAdded
// DOG total supply is fixed at etching (rune 840000:3). Cannot change.above the constant inwhales()to document why it's safe to hardcode.Not in this PR
fetchMultiple429 short-circuit) — correctness fix with wide blast radius across 8 handlers. Separate focused PR.actionfield restructure) — breaking/cosmetic, needs versioning story first.Test notes
No new dependencies. Changes are purely to error paths and a documentation comment — no behavior change on the happy path. Smoke-tested locally against the existing
doctor+run --action pulsecommands.