Skip to content

Remove the remaining invented 0 % / window values (VibeTV #289) - #16

Merged
marcus7989 merged 78 commits into
vibetvfrom
claude/289-c
Oct 29, 2026
Merged

marcus7989 merged 78 commits into
vibetvfrom
claude/289-c

Conversation

@DreamyTalesPAN

@DreamyTalesPAN DreamyTalesPAN commented Oct 28, 2026 •

Copy link
Copy Markdown
Collaborator

Ziel

Windows-Kunden sehen für alle verbleibenden Provider „nicht verfügbar" statt erfundener 0 % / Fenster / Reset-Zeiten (VibeTV-shop/vibetv#289, Folge von nesszer#285 Schritt 1).

Regel: keine neue Provider-Bedeutung · eine echte 0/N bleibt ein Erfolg (je Provider ein Test) · fehlender Zähler oder fehlende Gesamtmenge → Provider-Fehler, oder RateWindow::informational(...), wenn ein echtes zweites Fenster existiert · Guthaben/Kosten/Zähler ohne Nenner → informational. Jeder Fix hat einen roten Test davor.

Bitte zuerst #15 mergen (dieser PR baut darauf auf, Basis ist claude/missing-data-no-zero; nach dem Merge von #15 zieht GitHub die Basis nach).

Was enthalten ist

  • A (25 Provider): Abacus, Alibaba, Amp, Augment, Antigravity (legacy status), CodeBuddy, Codebuff, CommandCode, Devin, Doubao, Factory, JetBrains, Kilo, LiteLLM, LongCat, Manus, MiMo, MiniMax, Perplexity, Sub2API, T3 Chat, Warp, Z.ai, Zed, ZoomMate.
  • B (20 Provider): Azure, Bedrock, Claude Admin, Crof, CrossModel, Deepgram, DeepInfra, DeepSeek, Fireworks, Groq, Kimi K2, LLMProxy, Mistral, Ollama, OpenAI API, OpenRouter, Poe, Venice, Vertex AI, Wayfinder.
  • C: Antigravity exportiert usageKnown (NamedRateWindow); OpenCode/OpenCode Go: Reset nur, wenn die Quelle ihn nennt (kein now + 0), lokale Schätzung ohne aktive Sitzung ohne Reset; Sub2API-Ablauf ist informational statt Quota-Fenster; MiniMax Coding Plan rollt die geparste Uhrzeit um einen Tag statt now + 1 Tag.
  • P3 aus Review Report missing provider usage as unavailable instead of an invented 0% (VibeTV #285) #15: Dashboard bekommt ein additives Feld unavailable (aus is_informational bzw. !usage_known); dashboard.html blendet solche Fenster aus. Echte 0 % bleibt sichtbar.

Entscheidungen bei der Zusammenführung (bitte prüfen)

  • DeepInfra: Mit positivem Ausgabenlimit bleibt „suspended / amount owed / Guthaben ≤ 0" bei 100 % (Upstream Deep Infra tracking screwy steipete/CodexBar#2822); ohne Limit informational. Die Worker-Fassung hatte das auf informational gezogen.
  • Manus: Add-on- und Event-Guthaben waren noch 0-%-Fenster → informational.
  • MiniMax: reines Billing-Ergebnis (Tokens heute/30 Tage, Ausgaben, Methoden, Modelle) hat keinen Nenner → alle Fenster informational.
  • ZoomMate: „unlimited" ist informational („Unlimited credits"), auch ohne Zähler; fehlender Zähler/Cap bei begrenztem Konto bleibt Fehler.
  • Fehlertexte: Neun neue Fehlersätze enthielten Wörter, die die Companion-Gesundheitsprüfung als Setup-/Config-/Anmelde-Hinweis liest („missing", „configured", „config", „token"). Sie sind umformuliert („… response contains no …"), damit der Kunde den einen generischen „konnte nicht gelesen werden"-Satz sieht. Der Companion-Test dazu liegt im VibeTV-Draft.
  • Sub2API: Der Fehlerpfad aus A („no usage counters") und mein Ablauf-Fenster passen zusammen; nur der Test brauchte die neue Signatur.

Tests

  • cargo test -p codexbar --lib --jobs 2: 1970 grün, 4 rot. Die 4 roten (pi_family_tests::config_dir_must_stay_within_home, …::windows_shims_and_paths_are_normalized_for_dialect, codex_sessions::tests::normalizes_codex_root_to_sessions_dir, core::hooks::tests::config_matching_respects_enabled_flag) sind Windows-Pfadtests auf macOS und schlagen auf der unveränderten Basis genauso fehl.
  • cargo fmt --check sauber, git diff --check sauber. Clippy: keine Treffer in den geänderten Dateien (die übrigen Warnungen sind vorhandene Nicht-Windows-cfg-Warnungen).
  • Nicht geprüft: Windows-Lauf auf echter Hardware (erst nach dem Tag), opencode/scraper.rs ist toter Code und unverändert.

Bitte an Marcus

Nach dem Review: mergen und v0.60.3-vibetv.15 als Prerelease taggen. Der VibeTV-Draft-PR mit dem Pin-Bump wartet darauf (SHA-256 kommt vom Release).

🤖 Generated with Claude Code

…Sub2API, MiniMax, Antigravity)

- Antigravity: export NamedRateWindow.usage_known as usageKnown so an unknown
  lane is no longer read as a real 0 %.
- OpenCode / OpenCode Go: a percent without resetInSec has no reset time
  instead of resets_at = now.
- OpenCode Go local estimate: no usage in the last five hours means no session
  reset, not a made-up 5 h countdown.
- Sub2API: the subscription expiry is an informational row, not a 0 % window
  whose reset is the contract end.
- MiniMax: a coding-plan clock time that has passed rolls the parsed time by
  one day instead of becoming now + 1 day.

Each item has a test that failed before; the explicit resetInSec: 0 case stays
a reset (VibeTV nesszer#289 section C).
The dashboard window payload carried 0 % used / 100 % remaining for an
informational primary and for an Antigravity lane without usage, with no way
to tell them from a real zero. Add an additive `unavailable` key (omitted
when false) and let the built-in web UI skip those rows (Marcus's P3 on #15,
VibeTV nesszer#289).
@DreamyTalesPAN

Copy link
Copy Markdown
Collaborator Author

Wir übernehmen alle fünf Punkte aus deinem Review (CodeBuddy, Warp, Kilo, MiMo, Manus) und zusätzlich die Funde unserer eigenen Prüfung (Codebuff, Devin, Doubao, Sub2API, Venice, Abacus, MiniMax u. a.). Bitte nicht pushen, bis wir "fertig ()" melden – wir pushen per Merge-Commit, kein Force-Push, und ziehen #17 danach nach.

@DreamyTalesPAN

Copy link
Copy Markdown
Collaborator Author

fertig (f327cfc), zurück an dich. Neuer Head von #16: f327cfcb, per Fast-Forward, kein Force-Push.

Deine fünf Punkte

  • CodeBuddy — fertig (8630589): ein vollständig gemeldetes leeres Paket (0/0/0) trägt exakt 0 bei, das gültige Paket mit 25/100 bleibt als 25 % erhalten. Fehlende Paketfelder und ein leeres einzelnes Paket bleiben Fehler.
  • Warp — fertig (64dd812): isUnlimited:true ist Information ("Unlimited"), unabhängig von Zähler und Limit; eine gültige Bonusquote bleibt erhalten.
  • Kilo — fertig (5847a51): PAYG-Guthaben (totalBalance_mUsd) bleibt als Information ("$1.06 balance") ohne erfundene Quote.
  • MiMo — fertig (5c21933): fehlen die Plan-Daten, bleibt die Hauptquote "nicht verfügbar", das Guthaben ("5.00 CNY balance") bleibt sichtbar.
  • Manus — fertig (f8e32bc): Gesamt-, Add-on- und Event-Guthaben bleiben als Information, auch ohne Monats-/Refresh-Quote; ein gemeldetes 0 zählt als Wert, ein fehlender Wert wird nicht erfunden.

Zusätzlich aus unserer eigenen Prüfung (je ein Commit, je ein Test, der vor dem Fix rot war)

  • Codebuff — 12e93dc: Restbetrag ohne Quotenbasis bleibt als Information.
  • Devin — 1497599: Geldbetrag (overage_balance) bleibt ohne Tages-/Wochenquote; dca67e4: ein generischer used/limit-Zähler erzeugt keine zusätzliche Wochenquote.
  • Doubao — 6504a94: beobachtete Probe-Tokens bleiben als Information.
  • Sub2API — b5ddf28: leere Subscription verwirft Balance und Tagesnutzung nicht mehr.
  • Venice — bf9fbeb: canConsume:false behält die gemessene DIEM-Quote, die Sperre steht zusätzlich im Text.
  • Abacus — d9940e1: 0/0 ist Information statt 0-%-Quote.
  • MiniMax Coding Plan — 5f8a757: ohne Restzähler keine erfundene 100-%-Quote; d8c14aa: Unlimited als Information in Haupt-, Wochen- und Zusatzfenster; 508093b: Reset-Uhrzeit wird gegen den Kalendertag der angegebenen Zeitzone aufgelöst.
  • DeepInfra — 476cbad: Sperre/fehlendes Guthaben überschreiben die gemessene Budgetquote nicht mehr mit 100 % (Status steht im Text). Das ist eine bewusste Abweichung vom Upstream-Override; sag Bescheid, falls du ihn behalten willst.
  • OpenCode Go — 48c5522: echte Wochen-/Monatsfenster bleiben ohne Rolling-Fenster; 09789cd: die lokale SQLite-Auswertung exportiert keine Quoten mehr aus festen Konstanten, sondern beobachtete Kosten als Information.
  • Datenfehlertexte (Abacus, OpenCode, OpenCode Go, MiniMax, Manus) lesen sich für den Companion nicht mehr als Setup/Anmeldung — f327cfc.

Geprüft: cargo test -p codexbar: 1991 bestanden, 4 rot (die bekannten Windows-Pfad-Tests pi_family ×2, codex_sessions, hooks), cargo fmt --check und git diff --check sauber. Native Windows-/Companion-/UI-Prüfung des Heads steht noch aus.

#17 ist per Merge-Commit nachgezogen (0c5def4d).

@marcus7989 marcus7989 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

W182 re-review: ohne Befund (no P1/P2 findings) on f327cfcbbce7c8ff21006f1681dfdd2bcb4f0e05, stacked on #15 (53941bcc). Rechecked the delta since W180 (b6668e29) against Paul's response.

All five W180 findings are correctly addressed: CodeBuddy retains 25/100 alongside a complete empty package, Warp Unlimited is informational and preserves a real bonus quota, and Kilo/MiMo/Manus retain observed balances without inventing percentages. The seven original independent probes (including the previously noted Abacus 0/0 case) now all pass. The 14 additional corrections are plausible; the 26 review16 regression tests pass, and the changed branches preserve explicit zero and independent measured windows while leaving absent resets absent.

The two deliberate deviations are reasonable: DeepInfra retains measured budget usage and puts suspension/debt in its text instead of turning it into a fabricated 100%; OpenCode Go local history exposes observed costs without asserting server quotas from constants. Native Companion presentation of this information remains part of the Windows check.

Local cargo test -p codexbar --jobs 2: 1991 passed, 4 failed, 1 ignored. The four failures are the known macOS Windows-path cases (pi_family x2, codex_sessions, hooks), matching W180's head/base evidence. cargo fmt --all --check and diff whitespace checks pass. This is a code review, not native Windows/UI validation or merge/tag approval; no devices were used.

… tokens (review #16)

Kimi K2: a response with only cash_balance/voucher_balance is no longer an
error; both amounts reach the informational extra windows.
Doubao: an ambiguous request quota seen twice keeps the observed tokens as an
informational result instead of an error.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@DreamyTalesPAN

Copy link
Copy Markdown
Collaborator Author

@marcus7989 A second review pass on the PR head f327cfcb found two more places where real provider data is dropped. I confirmed both in the code and reproduced both with new tests.

1. Kimi K2 drops real cash/voucher amounts when there is no main balance (providers/kimik2/mod.rs). A response like {"code":0,"status":true,"data":{"cash_balance":12.5,"voucher_balance":3.25}} is parsed fine, but the early "no balance or usable quota" error fires before the informational cash/voucher windows are built. A VibeTV customer on Windows then sees a provider error instead of their real cash and voucher amounts (the primary window stays "Balance unavailable", never an invented 0 %).

2. Doubao loses the observed tokens when the request quota stays ambiguous (providers/doubao/mod.rs). When the first probe and the confirmation probe both return 200 with remaining-requests: 0, confirm_ambiguous_zero_remaining rebuilds the result from the headers only and returns "request quota is not reliable". The N tokens observed in probe information from the response body is lost. A VibeTV customer on Windows then sees a provider error instead of the real token count, with the request quota correctly shown as unavailable.

Red tests (before the fix): cash_or_voucher_without_main_balance_keep_their_amounts (Kimi K2) and review16_p2_ambiguous_zero_remaining_keeps_observed_tokens (Doubao) both failed. They pass now. A third Doubao test pins that the error stays when no tokens were observed.
Fix: Kimi K2 errors only if available balance, quota, voucher and cash are all missing. Doubao keeps the tokens as an informational window and drops only the ambiguous request quota. The diff is about 40 lines plus tests, with no new provider semantics.
Tests: cargo test -p codexbar --lib gives 1994 passed (the 1991 from before plus the 3 new tests) and 4 failed. The 4 are the macOS baseline failures from Windows paths (pi_family x2, normalizes_codex_root_to_sessions_dir, config_matching_respects_enabled_flag), which also fail on #15, #16 and #17 unchanged.

Branch: claude/289-c-p2-fix at cacb7c8dc32a5627327232fd552799848459614b, one commit on top of the #16 head f327cfcb. I did not push to claude/289-c.

Shall we push this onto the PR branch before you tag .15, or will you take it?

@DreamyTalesPAN

Copy link
Copy Markdown
Collaborator Author

We're taking over the push of our fix branch now (per your OK in VibeTV-shop/vibetv#284, 07:43) – please don't push to this branch until we report back.

@DreamyTalesPAN

Copy link
Copy Markdown
Collaborator Author

Joint Windows probe of #15–#17: PASS (details below; same text on all three PRs).

Build: local merge branch claude/probe-15-17 @ 8b8134d3 (#15 53941bcc + #16 cacb7c8d + #17 0c5def4d; clean merge, branch only, no PR). Built on a Windows runner like the release build (cargo build --release --bin codexbar, Rust 1.98.0, static CRT): codexbar 0.60.3, codexbar-cli.exe sha256 a7b3f8e95bee92f3e831159838365becb8366696e32987ba6c48350b25fe6ed8.
Windows unit tests (cargo test -p codexbar --lib, windows-latest): 2035 passed, 1 failed. The 4 path tests that fail on macOS pass on Windows. The one failure is codex_accounts::codex_desktop::tests::restart_uses_manifest_gui_and_leaves_standalone_cli_alone (it runs a PowerShell restart script on the runner); codex_accounts/ is identical to vibetv, so none of #15–#17 touches it. I did not re-run it on plain vibetv.
VibeTV app on real Windows (bench laptop, real VibeTV on the cable): CI installer 9999.0.357 (merge commit of VibeTV main 5c97812c), its codexbar-cli.exe replaced by the probe CLI after each install (sha verified).

Ready for your merge, then tag .14 for #15 and .15 for #16 + #17?

@DreamyTalesPAN

Copy link
Copy Markdown
Collaborator Author

Done (cacb7c8d): our fix branch claude/289-c-p2-fix (Kimi K2 cash/voucher amounts, Doubao observed tokens) is merged into this PR as a fast-forward, no force push; back to you. Unit tests: 1994 passed on macOS, plus the Windows run above. Fork CI reported no status on this head. Joint Windows probe result is in the comment above.

@marcus7989

Copy link
Copy Markdown
Owner

W211 · Beelink Windows validation, 2026-10-29 · STOP (environment blocker)

The exact native Rust 1.98.0 baseline/probe comparison could not start: HOMESTATION-WIN has no cargo/rustc/rustup on PATH, no user .cargo/.rustup directory, and no matching Rust/MSVC/Git executables in the checked tools/program directories. No compiler/toolchain was installed during this slot. This is an unfulfilled test environment, not an observed product regression; no cargo test exit codes exist and the known restart-test result remains unresolved.

Task results: (1) baseline 7614e4d vs probe 8b8134d BLOCKED before execution; (2) isolated #15 / .14 build and VibeTV smoke NOT RUN; (3) automatic Windows Usage/Refresh NOT RUN after the explicit stop condition; (4) NO MERGES, NO TAGS, no release workflow triggered.

Final baseline check passed: app 9999.0.2266, runtime a9e985be9d1500de8455edc26d62c9a66b52bd4f, VibeTV 5804558, Clippy, brightness 20, automatic codex/claude/cursor. All app files and 13/13 configs match the pre-slot backup byte-for-byte; Firefox process IDs and existing Codex CLI auth-file hash are unchanged. No login, reboot or OS switch performed. Current PR heads remain #15 53941bc, #16 cacb7c8, #17 0c5def4.

Local evidence: .local/reports/wincb16/BEELINK-W211.md; w211/tools-result.json and w211/final-result.json. The next native run needs a prepared Rust 1.98.0/MSVC build environment, or a separately approved cross-build/native-execution plan; it must not be reported as already tested.

@marcus7989
marcus7989 changed the base branch from claude/missing-data-no-zero to vibetv October 29, 2026 09:16
@marcus7989
marcus7989 merged commit 0654e45 into vibetv Oct 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants