Commit Graph

204 Commits

Author SHA1 Message Date
southseact-3d
8e937a6ff4 debug: try fetching subscription directly by ID to check customer mismatch
- Add direct API call to fetch subscription sub_0NYKZRvba3g5KJfp8R5jp
- Log customer ID comparison to detect mismatches
- Update user record if subscription belongs to different customer
- This will help identify if duplicate customers exist in Dodo
2026-02-12 11:50:14 +00:00
southseact-3d
2268a0e649 debug: log full API response to diagnose empty subscription results 2026-02-12 11:48:58 +00:00
southseact-3d
001993d0bc fix: query all subscriptions without status filter for customers with multiple subs
- Query ALL subscriptions for customer without status filter first
- This handles customers with multiple subscriptions across different statuses
- Returns first active subscription found, or most recent if none active
- Added detailed logging to show all subscription IDs and statuses found
- Fallback to check individual statuses including cancelled/expired
2026-02-12 11:45:53 +00:00
southseact-3d
2a603549f4 debug: add detailed logging for customer and subscription lookup
Add comprehensive DEBUG logs to trace through:
- Customer lookup by email (request and response details)
- Subscription lookup by customer ID (for each status)
- Entry point when plan change is initiated

This will help identify exactly where the lookup is failing.
2026-02-12 11:36:52 +00:00
southseact-3d
d82dcfd5e4 fix: improve customer lookup to prevent duplicate customers in Dodo
- Modified ensureDodoCustomer() to query existing customers by email before creating new ones
- This prevents duplicate customer records when dodoCustomerId is missing from database
- Added logging for both found existing customers and new customer creation
- Updated subscription lookup to check multiple statuses (active, pending, on_hold)
- Should resolve paid-to-paid and paid-to-free plan change issues for users missing subscription IDs
2026-02-12 11:30:52 +00:00
southseact-3d
ae871df0a0 fix: resolve subscription ID lookup and checkout URL issues
- Fix getBaseUrl() ReferenceError by changing to resolveBaseUrl(req) for free-to-paid upgrades
- Add subscription lookup by customer email when dodoSubscriptionId is missing
- Log critical issues when paid users have no subscription ID in database or Dodo
- Return clear error message to contact support when subscription cannot be found
- Prevent silent failures in plan changes from settings page
2026-02-12 11:09:45 +00:00
southseact-3d
c762470fa9 Align topup.html fonts with home.html: remove Space Grotesk, use Inter only 2026-02-12 10:49:09 +00:00
Liam Hetherington
f61ade810a Merge pull request #24 from southseact-3d/codex/fix-multiple-request-counting-issue
Limit tool-run loop for Chutes-like OpenAI routes and add regression test
2026-02-12 09:41:22 +00:00
Liam Hetherington
6a133b3038 Fix Chutes single-step tool loop detection for OpenAI-compatible routes 2026-02-12 09:41:03 +00:00
Liam Hetherington
b313994578 Delete Chutes AI Tool Call Issue Plan document
Removed detailed analysis and proposed solutions for the Chutes AI tool call counting issue.
2026-02-12 09:13:53 +00:00
southseact-3d
e2abb2ee98 fix 2 2026-02-11 20:16:01 +00:00
southseact-3d
a66c983360 Fix topup page header styling to match settings.html 2026-02-11 20:12:55 +00:00
southseact-3d
7d7388f571 Fix user profile dropdown z-index to appear above messages 2026-02-11 19:31:57 +00:00
southseact-3d
0513000a9e Fix builder page layout: make new chat and history buttons sticky at top on desktop
- Moved sticky positioning from mobile-only to global CSS for .top-left-actions

- Buttons now stay fixed at top above content on all screen sizes

- Includes various other app updates (version management, server improvements)
2026-02-11 19:23:23 +00:00
southseact-3d
e2a2dff301 Fix topup page: resolve JS error, improve styling, remove redundant buttons 2026-02-11 18:27:02 +00:00
southseact-3d
277ee351bf Fix redeclaration of const userChip in feature-requests.html 2026-02-11 18:20:03 +00:00
Liam Hetherington
196e0a98f5 Merge pull request #15 from southseact-3d/copilot/implement-secure-database-setup
Add encrypted SQLite database with JWT session management
2026-02-11 15:17:55 +00:00
Liam Hetherington
382a4abcb8 Merge branch 'main' into copilot/implement-secure-database-setup 2026-02-11 15:17:40 +00:00
Liam Hetherington
cb4edee1e0 Merge pull request #23 from southseact-3d/codex/analyze-tool-call-request-counting-issue
Cap Chutes provider tool orchestration to a single SDK step
2026-02-11 15:04:58 +00:00
Liam Hetherington
b6386d1777 Fix chutes tool calls to stay single-step 2026-02-11 15:03:23 +00:00
southseact-3d
f5537e3e0b docs: Add comprehensive plan for Chutes AI tool call counting issue
Documents the issue where tool calls count as separate Chutes AI requests,
proposed solutions, technical analysis, and user concerns about breaking
sequential workflows.

Includes:
- Root cause analysis of Vercel AI SDK multi-step execution
- 4 proposed solution options with pros/cons
- User concerns about model context and workflow breaks
- Code references and technical diagrams
- Recommended next steps for testing and implementation

Relates to: Tool call execution flow in session management
2026-02-11 13:53:06 +00:00
southseact-3d
5d91c86f90 Add Cohere as a provider for build messages in admin panel
- Add 'cohere' to DEFAULT_PROVIDERS and PLANNING_PROVIDERS arrays in admin.js
- Add Cohere option to provider limits dropdown in admin.html
- Add 'cohere' to DEFAULT_PROVIDER_SEEDS, PLANNING_PROVIDERS, and KNOWN_USAGE_PROVIDERS in server.js

Cohere was already integrated in the opencode backend (SDK installed, provider registered, icons defined). These changes make it available in the admin panel for build message configuration.
2026-02-11 13:25:16 +00:00
southseact-3d
71c1677932 chore: remove excessive debug logging from ensureOpencodeConfig 2026-02-11 12:03:16 +00:00
southseact-3d
d2640eee5d fix: extract provider from model name (e.g., chutes/model-name)
- Parse model names like 'chutes/deepseek-ai/DeepSeek-V3.2-TEE'
- Extract provider prefix before '/' to detect chutes, cerebras, etc.
- This fixes provider detection when admin panel sets wrong provider
2026-02-11 11:49:43 +00:00
southseact-3d
f1fb336f4d debug: log all models and filter for chutes models 2026-02-11 11:44:48 +00:00
southseact-3d
b85cc73a4d fix: handle both string and object formats in providers array
- Support providers as array of strings: [opencode, chutes]
- Support providers as array of objects: [{provider: opencode}]
- This fixes provider detection for Chutes and other providers
2026-02-11 11:41:22 +00:00
southseact-3d
bddc710a90 debug: add detailed logging for adminModels and provider detection
- Log adminModels count and sample data
- Log CHUTES_API_KEY status and prefix
- Log detected providers from adminModels
2026-02-11 11:37:06 +00:00
southseact-3d
3ec9177082 fix: load adminModels before sessions in bootstrap sequence
- Move loadAdminModelStore() before loadState() in bootstrap()
- This ensures adminModels is available when ensureOpencodeConfig is called
- Fixes issue where Chutes provider was not being configured
2026-02-11 11:27:43 +00:00
southseact-3d
18d9e18978 debug: add detailed logging for Chutes API calls
- Log API key prefix to verify key is loaded
- Log full error response from Chutes API
- Log success count when models are fetched
2026-02-11 11:20:04 +00:00
southseact-3d
49092c3229 fix: ensure adminModels is loaded before checking providers in ensureOpencodeConfig
- Add check to load adminModels if not already loaded
- Add error handling for models.dev fetch failures
- Log provider source (models.dev vs built-in) for debugging
2026-02-11 11:18:56 +00:00
southseact-3d
17792d39a0 feat: dynamic provider model loading from models.dev
- Add fetchModelsDevProviderModels() function with 1-hour caching
- Update ensureOpencodeConfig() to dynamically load all models for configured providers
- Support Chutes, Cerebras, Groq, Google, and Nvidia providers
- Only fetch models for providers actually used in adminModels
- Cache models.dev data to reduce API calls and improve performance

This allows any model from models.dev to work when added in the admin panel,
instead of requiring hardcoded model definitions.
2026-02-11 10:53:37 +00:00
southseact-3d
d0105ff967 fix: add DeepSeek V3.2 TEE model to Chutes provider config with baseURL 2026-02-11 10:44:48 +00:00
Liam Hetherington
633f005f6c Merge pull request #22 from southseact-3d/codex/show-undo-and-redo-buttons-with-zero-output
Show builder undo/redo controls when message has zero output
2026-02-11 10:26:12 +00:00
Liam Hetherington
6cc4258d75 Show undo/redo controls even when builder output is empty 2026-02-11 09:46:54 +00:00
Liam Hetherington
e6485c6bbf Merge pull request #20 from southseact-3d/dependabot/npm_and_yarn/chat/npm_and_yarn-0d7ef37a24
Bump multer from 1.4.5-lts.2 to 2.0.2 in /chat in the npm_and_yarn group across 1 directory
2026-02-11 09:43:07 +00:00
Liam Hetherington
5a049a2e89 Merge pull request #21 from southseact-3d/dependabot/cargo/opencode/packages/desktop/src-tauri/cargo-65e7861b48
Bump the cargo group across 1 directory with 2 updates
2026-02-11 09:42:47 +00:00
southseact-3d
1ce02060e8 fix: pass provider API keys (CHUTES, GROQ, GOOGLE, NVIDIA) to OpenCode CLI execution environment 2026-02-11 09:04:15 +00:00
dependabot[bot]
58a1d40744 Bump the cargo group across 1 directory with 2 updates
Bumps the cargo group with 2 updates in the /opencode/packages/desktop/src-tauri directory: [bytes](https://github.com/tokio-rs/bytes) and [time](https://github.com/time-rs/time).


Updates `bytes` from 1.11.0 to 1.11.1
- [Release notes](https://github.com/tokio-rs/bytes/releases)
- [Changelog](https://github.com/tokio-rs/bytes/blob/master/CHANGELOG.md)
- [Commits](https://github.com/tokio-rs/bytes/compare/v1.11.0...v1.11.1)

Updates `time` from 0.3.44 to 0.3.47
- [Release notes](https://github.com/time-rs/time/releases)
- [Changelog](https://github.com/time-rs/time/blob/main/CHANGELOG.md)
- [Commits](https://github.com/time-rs/time/compare/v0.3.44...v0.3.47)

---
updated-dependencies:
- dependency-name: bytes
  dependency-version: 1.11.1
  dependency-type: indirect
  dependency-group: cargo
- dependency-name: time
  dependency-version: 0.3.47
  dependency-type: indirect
  dependency-group: cargo
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-02-10 21:25:04 +00:00
dependabot[bot]
c0eae5f3b4 Bump multer in /chat in the npm_and_yarn group across 1 directory
Bumps the npm_and_yarn group with 1 update in the /chat directory: [multer](https://github.com/expressjs/multer).


Updates `multer` from 1.4.5-lts.2 to 2.0.2
- [Release notes](https://github.com/expressjs/multer/releases)
- [Changelog](https://github.com/expressjs/multer/blob/main/CHANGELOG.md)
- [Commits](https://github.com/expressjs/multer/compare/v1.4.5-lts.2...v2.0.2)

---
updated-dependencies:
- dependency-name: multer
  dependency-version: 2.0.2
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-02-10 21:23:34 +00:00
Liam Hetherington
e58ebdcc4d Merge pull request #6 from southseact-3d/dependabot/npm_and_yarn/opencode/packages/console/app/npm_and_yarn-118d70433f
Bump the npm_and_yarn group across 3 directories with 4 updates
2026-02-10 21:22:40 +00:00
southseact-3d
566442327a Fix: Add Chutes and Cerebras provider config to opencode.json
When models from providers like Chutes or Cerebras were added via the admin panel,
they didn't work in the builder page because the opencode.json config file only
included the Ollama provider configuration.

This fix adds Chutes and Cerebras provider configurations to the opencode.json
file when their respective API keys are available in environment variables
(CHUTES_API_KEY and CEREBRAS_API_KEY).

Fixes the issue where chutes/deepseek-ai/DeepSeek-V3.2-TEE and similar models
would fail to load from the builder page.
2026-02-10 19:51:39 +00:00
southseact-3d
8b96273f47 builder: skip OpenCode verification when OPENCODE_REQUIRE_REPO=false 2026-02-10 19:09:22 +00:00
southseact-3d
bc45e3f964 builder: adapt OpenCode integration for Docker deployment; disable repo verification, remove JSON flag usage, parse text models, fix redo flow and session listing 2026-02-10 18:58:14 +00:00
southseact-3d
1af1f7b266 try again 2026-02-10 18:43:41 +00:00
southseact-3d
f1d3dce73c fix opencode error 2026-02-10 18:32:41 +00:00
southseact-3d
8e8129d71c Fix Editor.js plugin loading errors in blog admin
- Add multiple fallback global variable names for Editor.js plugins
- Add debug logging to track plugin availability
- Add error handling for editor initialization
- Ensure at least paragraph tool is available before initializing
- Fix ReferenceError: List is not defined when opening post modal
2026-02-10 18:13:13 +00:00
southseact-3d
c38dc20733 Create GitHub releases for pre-built OpenCode CLI and update Dockerfile 2026-02-10 16:22:47 +00:00
southseact-3d
33a42040d6 Update Bun to 1.3.8 to match project requirements 2026-02-10 16:09:25 +00:00
southseact-3d
19abee65c8 Move Node.js installation before Bun 2026-02-10 16:03:59 +00:00
southseact-3d
0860fc0028 Simplify Bun installation using npm 2026-02-10 16:01:21 +00:00