fix
This commit is contained in:
parent
b24683a5ce
commit
fd62d5ee41
@ -14,6 +14,7 @@ from core.app.features.rate_limiting import RateLimit
|
||||
from libs.helper import RateLimiter
|
||||
from models.model import Account, App, AppMode, EndUser
|
||||
from models.workflow import Workflow
|
||||
from services.billing_service import BillingService
|
||||
from services.errors.llm import InvokeRateLimitError
|
||||
from services.workflow_service import WorkflowService
|
||||
|
||||
@ -42,8 +43,7 @@ class AppGenerateService:
|
||||
# system level rate limiter
|
||||
if not dify_config.BILLING_ENABLED:
|
||||
# check if it's free plan
|
||||
# limit_info = BillingService.get_info(app_model.tenant_id)
|
||||
limit_info = {"subscription": {"plan": "sandbox"}}
|
||||
limit_info = BillingService.get_info(app_model.tenant_id)
|
||||
if limit_info["subscription"]["plan"] == "sandbox":
|
||||
if cls.system_rate_limiter.is_rate_limited(app_model.tenant_id):
|
||||
raise InvokeRateLimitError(
|
||||
|
Loading…
Reference in New Issue
Block a user