Repository navigation
Commit 45251ac
feat(claude): full SDK message coverage with type-level exhaustiveness guards
Log-driven audit of real captured traffic (verification runs + wire
probes) found api_retry storms rendering as 10 warning rows per 502 and
several union subtypes falling into the unknown-subtype warning path.
- api_retry → session.state.changed heartbeat (terminal error path
already reports the real failure)
- session_state_changed → authoritative session.state.changed mapping
- notification → warning row only for high/immediate priority
- model_refusal_fallback, local_command_output, plugin_install,
commands_changed, memory_recall, elicitation_complete,
prompt_suggestion → deliberately consumed, no spurious rows
- default branches now narrow to never: a new SDK message type or
subtype fails typecheck instead of silently warning at runtime; the
runtime fallback still catches undeclared wire-only subtypes
Co-Authored-By: Claude Fable 5 <[email protected]>1 parent 8a9ebf4 commit 45251ac
2 files changed
Lines changed: 133 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1705 | 1705 | | |
1706 | 1706 | | |
1707 | 1707 | | |
| 1708 | + | |
| 1709 | + | |
| 1710 | + | |
| 1711 | + | |
| 1712 | + | |
| 1713 | + | |
| 1714 | + | |
| 1715 | + | |
| 1716 | + | |
| 1717 | + | |
| 1718 | + | |
| 1719 | + | |
| 1720 | + | |
| 1721 | + | |
| 1722 | + | |
| 1723 | + | |
| 1724 | + | |
| 1725 | + | |
| 1726 | + | |
| 1727 | + | |
1708 | 1728 | | |
1709 | | - | |
1710 | | - | |
| 1729 | + | |
| 1730 | + | |
| 1731 | + | |
| 1732 | + | |
| 1733 | + | |
| 1734 | + | |
| 1735 | + | |
| 1736 | + | |
| 1737 | + | |
| 1738 | + | |
| 1739 | + | |
| 1740 | + | |
| 1741 | + | |
| 1742 | + | |
| 1743 | + | |
| 1744 | + | |
| 1745 | + | |
| 1746 | + | |
| 1747 | + | |
| 1748 | + | |
| 1749 | + | |
| 1750 | + | |
| 1751 | + | |
| 1752 | + | |
1711 | 1753 | | |
1712 | 1754 | | |
1713 | | - | |
1714 | | - | |
| 1755 | + | |
| 1756 | + | |
| 1757 | + | |
| 1758 | + | |
| 1759 | + | |
| 1760 | + | |
1715 | 1761 | | |
1716 | | - | |
| 1762 | + | |
1717 | 1763 | | |
1718 | 1764 | | |
1719 | | - | |
| 1765 | + | |
| 1766 | + | |
| 1767 | + | |
| 1768 | + | |
| 1769 | + | |
| 1770 | + | |
| 1771 | + | |
| 1772 | + | |
1720 | 1773 | | |
1721 | | - | |
1722 | | - | |
1723 | | - | |
| 1774 | + | |
| 1775 | + | |
| 1776 | + | |
1724 | 1777 | | |
1725 | | - | |
| 1778 | + | |
| 1779 | + | |
1726 | 1780 | | |
1727 | 1781 | | |
1728 | 1782 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2708 | 2708 | | |
2709 | 2709 | | |
2710 | 2710 | | |
| 2711 | + | |
| 2712 | + | |
| 2713 | + | |
| 2714 | + | |
| 2715 | + | |
2711 | 2716 | | |
2712 | 2717 | | |
2713 | 2718 | | |
| |||
2752 | 2757 | | |
2753 | 2758 | | |
2754 | 2759 | | |
| 2760 | + | |
| 2761 | + | |
| 2762 | + | |
| 2763 | + | |
| 2764 | + | |
| 2765 | + | |
| 2766 | + | |
| 2767 | + | |
| 2768 | + | |
| 2769 | + | |
| 2770 | + | |
| 2771 | + | |
| 2772 | + | |
| 2773 | + | |
| 2774 | + | |
| 2775 | + | |
| 2776 | + | |
| 2777 | + | |
| 2778 | + | |
| 2779 | + | |
| 2780 | + | |
| 2781 | + | |
| 2782 | + | |
| 2783 | + | |
| 2784 | + | |
| 2785 | + | |
| 2786 | + | |
| 2787 | + | |
| 2788 | + | |
| 2789 | + | |
| 2790 | + | |
| 2791 | + | |
| 2792 | + | |
| 2793 | + | |
| 2794 | + | |
| 2795 | + | |
| 2796 | + | |
| 2797 | + | |
| 2798 | + | |
| 2799 | + | |
| 2800 | + | |
| 2801 | + | |
| 2802 | + | |
| 2803 | + | |
| 2804 | + | |
| 2805 | + | |
2755 | 2806 | | |
2756 | 2807 | | |
2757 | 2808 | | |
| |||
2771 | 2822 | | |
2772 | 2823 | | |
2773 | 2824 | | |
2774 | | - | |
| 2825 | + | |
| 2826 | + | |
| 2827 | + | |
| 2828 | + | |
| 2829 | + | |
| 2830 | + | |
| 2831 | + | |
2775 | 2832 | | |
2776 | 2833 | | |
2777 | | - | |
| 2834 | + | |
2778 | 2835 | | |
2779 | 2836 | | |
2780 | 2837 | | |
| 2838 | + | |
2781 | 2839 | | |
2782 | 2840 | | |
2783 | 2841 | | |
| |||
2885 | 2943 | | |
2886 | 2944 | | |
2887 | 2945 | | |
2888 | | - | |
| 2946 | + | |
| 2947 | + | |
| 2948 | + | |
| 2949 | + | |
| 2950 | + | |
| 2951 | + | |
| 2952 | + | |
2889 | 2953 | | |
2890 | 2954 | | |
2891 | | - | |
| 2955 | + | |
2892 | 2956 | | |
2893 | 2957 | | |
2894 | 2958 | | |
| 2959 | + | |
2895 | 2960 | | |
2896 | 2961 | | |
2897 | 2962 | | |
| |||
0 commit comments