@yagni-app/code-staging 1.2.15-staging.2655.1 → 1.2.15-staging.2658.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -131,6 +131,8 @@ function incompleteHandoff(r) {
|
|
|
131
131
|
* against stderr/errorMessage only — never a stage's real output.
|
|
132
132
|
*/
|
|
133
133
|
const CREDIT_EXHAUSTION_RE = /out of credits|insufficient_quota|payment required|\b402\b/;
|
|
134
|
+
/** The proxy's 402 where the workspace can buy credits (`BUY_CREDITS_SENTENCE`). */
|
|
135
|
+
const BUY_CREDITS_RE = /Buy more on Settings/;
|
|
134
136
|
/**
|
|
135
137
|
* The run-scoped budget shapes: a Run's own approved budget or model-request
|
|
136
138
|
* limit, which the proxy refuses with a 429 typed `insufficient_quota`. The
|
|
@@ -169,9 +171,14 @@ export function creditExhaustionReason(r) {
|
|
|
169
171
|
}
|
|
170
172
|
if (!CREDIT_EXHAUSTION_RE.test(hay))
|
|
171
173
|
return undefined;
|
|
172
|
-
// "out of YAGNI credits" is the backend's marker
|
|
173
|
-
//
|
|
174
|
-
|
|
174
|
+
// "out of YAGNI credits" is the backend's marker. The act is the proxy's
|
|
175
|
+
// own (`moreCreditsSentence` in the backend): where credit packs are for
|
|
176
|
+
// sale its 402 says to buy them on Settings → Spending (YAG-1604), else
|
|
177
|
+
// to email.
|
|
178
|
+
const act = BUY_CREDITS_RE.test(hay)
|
|
179
|
+
? "Buy more on Settings → Spending, or email support@yagni.app"
|
|
180
|
+
: "Email support@yagni.app for more credits";
|
|
181
|
+
return `the workspace is out of YAGNI credits (the model proxy returned 402). ${act}, then re-run /go.`;
|
|
175
182
|
}
|
|
176
183
|
/** How a reviewer is named in the round's record: its lens, or the lane's one reviewer. */
|
|
177
184
|
function reviewerName(lens) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yagni-app/code-staging",
|
|
3
|
-
"version": "1.2.15-staging.
|
|
3
|
+
"version": "1.2.15-staging.2658.1",
|
|
4
4
|
"description": "YAGNI Code: a terminal coding agent that already knows your company. One YAGNI login routes the model and grounds the agent in your team's context.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"author": "YAGNI, Inc. <jack@yagni.app> (https://yagni.app)",
|
|
@@ -58,5 +58,5 @@
|
|
|
58
58
|
"turndown": "^7.2.4",
|
|
59
59
|
"typebox": "^1.3.15"
|
|
60
60
|
},
|
|
61
|
-
"yagniSourceSha": "
|
|
61
|
+
"yagniSourceSha": "e1dcb8813fdae2537eb099aeae4ed6d209313302"
|
|
62
62
|
}
|