Skip to content

Fix legacy CLI auth code parsing#626

Merged
jahooma merged 3 commits intomainfrom
jahooma/debug-invalid-auth-code
May 8, 2026
Merged

Fix legacy CLI auth code parsing#626
jahooma merged 3 commits intomainfrom
jahooma/debug-invalid-auth-code

Conversation

@jahooma
Copy link
Copy Markdown
Contributor

@jahooma jahooma commented May 8, 2026

Adds fallback parsing for legacy hyphen-delimited CLI auth codes in both Codebuff and Freebuff onboarding helpers while keeping the existing dot-delimited parser unchanged.
This fixes invalid-code failures for codes shaped like fingerprintId-expiresAt-hash, which still go through the existing hash and expiry validation before being accepted.
Adds targeted parser tests for both apps, logs auth-code dot/hyphen separator counts in Freebuff invalid-code warnings, and gives chat completions success fetch-path tests the same extended timeout as neighboring provider-path tests to avoid CI-only 5s timeout flakes.

Validation: bun test web/src/app/onboard/tests/helpers.test.ts freebuff/web/src/app/onboard/tests/helpers.test.ts; bun test web/src/app/api/v1/chat/completions/tests/completions.test.ts; git diff --check.

@jahooma jahooma merged commit 51e5592 into main May 8, 2026
35 checks passed
@jahooma jahooma deleted the jahooma/debug-invalid-auth-code branch May 8, 2026 22:51
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.

1 participant