Repository navigation
Description
Description
Dear OpenCode Team,
I am writing to report a critical bug in the OpenCode Go quota calculation logic that is causing premature service refusal and negatively impacting paying subscribers.
The Problem
According to your official documentation, OpenCode Go usage limits are defined in dollar amounts:
- 5-hour limit — $12 usage allowance
- Weekly limit — $30 usage allowance
- Monthly limit — $60 usage allowance
The documentation explicitly states: "限制以美元价值定义" (Limits are defined in dollar value). This means that quota consumption should be calculated by summing the actual dollar cost of each API request across each time window, and blocking requests only when the cumulative dollar spend reaches the respective cap ($12, $30, or $60).
However, the current implementation appears to be calculating quota exhaustion by summing percentage-based usage across individual models instead. When the sum of these percentages reaches 100%, the system refuses further requests—regardless of the actual dollar amount spent.
Observed Impact
This is not an isolated issue. Multiple users have reported the same behavior:
- One subscriber reported that after spending only $7.50 (out of a $30 weekly limit), their weekly quota showed 100% used and they were completely blocked from using Go models for 3 days.
- Another user with the $60/month plan reported that their 5-hour limit was consumed way too fast despite very low actual spend, with monthly usage already at 37% in just 2 days while total spent was less than $5.
- A separate issue documented the same symptom: "Go quota shows 100% exhausted but visible usage is only ~$20".
The common thread across all these reports is clear: the quota meter claims far more consumption than the actual dollar amount shown in the usage dashboard.
Why This Matters
This bug fundamentally contradicts the advertised pricing model. Subscribers are paying $10/month (or $5 for the first month) based on the understanding that they receive $12/5hr, $30/week, and $60/month of actual dollar-value usage. When the system blocks requests at a fraction of the promised dollar limit, it constitutes a material deviation from the service as described.
Paying customers are being locked out of a service they've prepaid for, often days before their quota should logically reset. This undermines trust in the platform and creates a poor user experience.
Requested Fix
I kindly request that you:
-
Correct the quota calculation logic to track and enforce limits based on cumulative dollar spend across each time window, as documented—not by summing model-specific percentages.
-
Ensure the usage dashboard displays consistent data—the dollar amount shown should match the quota consumption calculation.
-
Consider providing retroactive quota adjustments for subscribers who were incorrectly blocked due to this bug.
I am happy to provide additional details, screenshots, or assist with testing if needed. Please let me know if you require any further information.
Thank you for your attention to this matter. I look forward to your response.
Sincerely,
Heal
hanlie_heal@qq.com
Plugins
No response
OpenCode version
No response
Steps to reproduce
No response
Screenshot and/or share link
No response
Operating System
No response
Terminal
No response
Activity
github-actions commentedon Sep 5, 2026
This issue doesn't fully meet our contributing guidelines.
What needs to be fixed:
_No response_. These are needed for a valid bug report.Please edit this issue to address the above within 2 hours, or it will be automatically closed.
This issue might be a duplicate of existing issues. Please check:
If you believe this was flagged incorrectly, please let a maintainer know.
github-actions commentedon Sep 5, 2026
This issue has been automatically closed because it was not updated to meet our contributing guidelines within the 2-hour window.
Feel free to open a new issue that follows our issue templates.