spacehub

surshar / claude-code

Claude Code is an agentic coding tool that lives in your terminal, understands your codebase, and helps you code faster by executing routine tasks, explaining complex code, and handling git workflows - all through natural language commands.

Built by Anthropic · github.com/anthropics

mods/telemetry: a Choice member may carry a hyphen, as the built-in panel's merge-base doesBrowse files
poteat authored on Sep 11, 2026 parent 8dfc5aa · commit 1e6e5c750b7b
3 changed files+9 -7compared with 8dfc5aa
Mmods/telemetry/hooks/entries/checked-value/checked-value.ts
Mmods/telemetry/hooks/entries/choice-token/choice-token.ts
Mmods/telemetry/hooks/telemetry-types/choice/choice.ts
@@ -60,7 +60,7 @@
6060
6161 if (!isTokenList) {
6262 throw refusal(
63- `props.${key}.of: a list of 1 to ${CHOICES_LIMIT} ` + `snake_case tokens`,
63+ `props.${key}.of: a list of 1 to ${CHOICES_LIMIT} ` + `lowercase tokens`,
6464 method,
6565 )
6666 }
@@ -1,6 +1,7 @@
11 /**
2- * The shape of a Choice member: a snake_case token of at most 64 characters,
3- * which may start with a digit (a bucket such as `110_to_143`), unlike a name
4- * or a key (TOKEN).
2+ * The shape of a Choice member: a lowercase token of at most 64 characters,
3+ * of letters, digits, `_` and `-`, which may start with a digit (a bucket
4+ * such as `110_to_143`) and carry a hyphen (a kind such as `merge-base`),
5+ * unlike a name or a key (TOKEN).
56 */
6-export const CHOICE_TOKEN = /^[a-z0-9][a-z0-9_]{0,63}$/
7+export const CHOICE_TOKEN = /^[a-z0-9][a-z0-9_-]{0,63}$/
@@ -2,7 +2,8 @@
22 * A string property: the value and the list it is chosen from, declared
33 * beside it, so no free text reaches the row.
44 *
5- * Every member of `of` is a snake_case token, which may start with a digit,
6- * at most CHOICES_LIMIT of them; `value` is one of them.
5+ * Every member of `of` is a lowercase token of letters, digits, `_` and
6+ * `-`, which may start with a digit, at most CHOICES_LIMIT of them; `value`
7+ * is one of them.
78 */
89 export type Choice = { value: string; of: readonly string[] }