glanceapp/glance · error
application name, client ID and client secret are required
Error message
application name, client ID and client secret are required
What it means
Thrown by the reddit widget's initialize() when app-auth is partially filled in. If any of name, id, or secret is set, all three must be set; app-auth is opt-in for OAuth-based Reddit API access with higher rate limits than anonymous JSON endpoints. Glance enables app auth only when the triple is complete.
Source
Thrown at internal/glance/widget-reddit.go:88
if s != "hot" && s != "new" && s != "top" && s != "rising" {
widget.SortBy = "hot"
}
p := widget.TopPeriod
if p != "hour" && p != "day" && p != "week" && p != "month" && p != "year" && p != "all" {
widget.TopPeriod = "day"
}
if widget.RequestURLTemplate != "" {
if !strings.Contains(widget.RequestURLTemplate, "{REQUEST-URL}") {
return errors.New("no `{REQUEST-URL}` placeholder specified")
}
}
a := &widget.AppAuth
if a.Name != "" || a.ID != "" || a.Secret != "" {
if a.Name == "" || a.ID == "" || a.Secret == "" {
return errors.New("application name, client ID and client secret are required")
}
a.enabled = true
}
widget.
withTitle("r/" + widget.Subreddit).
withTitleURL("https://www.reddit.com/r/" + widget.Subreddit + "/").
withCacheDuration(30 * time.Minute)
return nil
}
func (widget *redditWidget) update(ctx context.Context) {
posts, err := widget.fetchSubredditPosts()
if !widget.canContinueUpdateAfterHandlingErr(err) {
return
}
View on GitHub (pinned to 91324e8de7)
Solutions
- Fill in all three keys under app-auth: name (any label), id (client ID), secret (client secret) from your Reddit app settings
- Double-check indentation so all three keys sit directly under app-auth
- If you do not want app auth, remove the entire app-auth block rather than leaving partial values
Example fix
# before app-auth: id: abc123 secret: xyz789 # after app-auth: name: my-glance-app id: abc123 secret: xyz789
Defensive patterns
Strategy: validation
Validate before calling
aa = w.get('app-auth')
if aa is not None:
missing = [k for k in ('name', 'id', 'secret') if not aa.get(k)]
if missing:
raise ValueError(f'app-auth is partial; missing: {missing}') Type guard
type AppAuth = { name: string; id: string; secret: string };
function isCompleteAppAuth(v: unknown): v is AppAuth {
if (typeof v !== 'object' || v === null) return false;
const o = v as Record<string, unknown>;
return ['name', 'id', 'secret'].every(k => typeof o[k] === 'string' && o[k].length > 0);
} Prevention
- Create the Reddit app first, then fill all three app-auth keys in one edit
- Inject the secret from a secrets manager instead of hand-editing, so blanks fail at deploy time
- Remove the whole app-auth block if anonymous access is enough
When it happens
Trigger: An app-auth block with only id and secret (missing name); only name set (pasting the app name first and saving); a secret that YAML decodes as empty (quoted-empty or null); whitespace-only values.
Common situations: Creating a Reddit 'script' app and copying two of the three values; rotating the client secret and leaving it blank during the edit; assuming name is optional because it is just a label.
Related errors
- subreddit is required
- no `{REQUEST-URL}` placeholder specified
- URL is required
- nested groups are not supported
- split columns inside of groups are not supported
AI-assisted analysis of glanceapp/glance@91324e8de7 (2026-08-15).
Data as JSON: /api/errors/95a86b244a128706.
Report an issue: GitHub.