langgenius/dify · warning
Trial app feature is not enabled.
Error message
Trial app feature is not enabled.
What it means
HTTP 403 from the `trial_feature_enable` decorator (controllers/console/explore/wraps.py). It calls `RecommendedAppService.is_trial_app_enabled()`, which returns True only when `DEPLOYMENT_EDITION == CLOUD` AND `ENABLE_TRIAL_APP` is set. On any other deployment, every route wrapped with `@trial_feature_enable` aborts with `Trial app feature is not enabled.`
Source
Thrown at api/controllers/console/explore/wraps.py:111
)
if account_trial_app_record:
if account_trial_app_record.count >= trial_app.trial_limit:
raise TrialAppLimitExceeded()
return view(app, *args, **kwargs)
return decorated
if view:
return decorator(view)
return decorator
def trial_feature_enable[**P, R](view: Callable[P, R]):
@wraps(view)
def decorated(*args: P.args, **kwargs: P.kwargs):
if not RecommendedAppService.is_trial_app_enabled():
abort(403, "Trial app feature is not enabled.")
return view(*args, **kwargs)
return decorated
class InstalledAppResource(Resource):
# must be reversed if there are multiple decorators
method_decorators = [
user_allowed_to_access_app,
installed_app_required,
account_initialization_required,
login_required,
]
class TrialAppResource(Resource):
# must be reversed if there are multiple decoratorsView on GitHub (pinned to ef8544b173)
Solutions
- If on cloud, set `ENABLE_TRIAL_APP=true` in the deployment config.
- If self-hosted/enterprise, do not expose trial-app UI — the feature is cloud-only by design.
- Gate the trial-app UI client-side on the `/system-features` flag so users never hit the 403.
- Confirm `DEPLOYMENT_EDITION` is correctly set to `CLOUD` in the running config.
Example fix
# before ENABLE_TRIAL_APP=false # after (cloud only) ENABLE_TRIAL_APP=true
Defensive patterns
Strategy: validation
Validate before calling
from configs import dify_config
from enums import DeploymentEdition
def trial_enabled() -> bool:
return (
dify_config.DEPLOYMENT_EDITION == DeploymentEdition.CLOUD
and bool(dify_config.ENABLE_TRIAL_APP)
)
if not trial_enabled():
# do not call trial-app endpoints
... Type guard
def is_trial_app_available(features) -> bool:
return bool(getattr(features, "enable_trial_app", False)) Try / catch
try:
resp = client.post("/explore/trial-apps/...", ...)
except HTTPError as err:
if err.response.status_code == 403:
# trial app disabled — hide trial UI
...
raise Prevention
- Hide trial-app UI on non-cloud deployments.
- On cloud, set ENABLE_TRIAL_APP=true if the feature is intended.
- Gate trial-app affordances on /system-features.
- Confirm DEPLOYMENT_EDITION is correctly set to CLOUD.
When it happens
Trigger: Hitting any explore/trial-app route (e.g. installing or running a trial app) on a deployment where `DEPLOYMENT_EDITION != CLOUD` or where cloud is set but `ENABLE_TRIAL_APP` is false/missing.
Common situations: Self-hosted or enterprise deployment trying to use trial apps; cloud deployment with `ENABLE_TRIAL_APP` not toggled on; feature flag flipped off mid-session.
Related errors
- This feature requires a paid plan.
- The workspace custom feature has reached the limit of your s
- speech_to_text_disabled
- app_suggested_questions_after_answer_disabled
- account_in_freeze
AI-assisted analysis of langgenius/dify@ef8544b173 (2026-08-12).
Data as JSON: /api/errors/d1a655fd018e1f3b.
Report an issue: GitHub.