Foundry376/Mailspring · error

Grammar check service is temporarily unavailable.

Error message

Grammar check service is temporarily unavailable.

What it means

Thrown when the identity backend proxies to the LanguageTool service and gets HTTP 502 back, i.e. the upstream grammar backend is down or unreachable. Signals a server-side outage, not a problem with the user's text or account.

Source

Thrown at app/internal_packages/composer-grammar-check/lib/grammar-check-service.ts:143

        json: true,
        body: {
          messageId,
          text,
          language: language || this.language,
        },
      });
    } catch (err) {
      // 400 = quota reached ("Quota Reached")
      if (err.statusCode === 400) {
        throw new UsageExceededError();
      }
      // 429 = rate limited — surface as a transient error, caller will retry on next dirty check
      if (err.statusCode === 429) {
        throw new Error('Grammar check rate limit reached, please try again shortly.');
      }
      // 502 = LanguageTool backend unavailable
      if (err.statusCode === 502) {
        throw new Error('Grammar check service is temporarily unavailable.');
      }
      throw err;
    }

    const filtered = data.matches.filter((match) => match.rule.issueType !== 'misspelling');

    return filtered.map((match) => ({
      offset: match.offset,
      length: match.length,
      message: match.message,
      shortMessage: match.shortMessage || '',
      replacements: match.replacements.map((r) => r.value),
      ruleId: match.rule.id,
      ruleDescription: match.rule.description,
      category: match.rule.category.id,
      categoryName: match.rule.category.name,
      issueType: match.rule.issueType,
      sentence: match.sentence,

View on GitHub (pinned to 648c685d60)

Solutions

  1. Retry the check after a delay; 502 is typically transient
  2. Disable or grey out grammar checking until the service responds successfully to avoid repeated errors
Defensive patterns

Strategy: retry

When it happens

Trigger: Thrown at app/internal_packages/composer-grammar-check/lib/grammar-check-service.ts:143 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of Foundry376/Mailspring@648c685d60 (2026-09-03). Data as JSON: /api/errors/dcdc9807cd5a6b03. Report an issue: GitHub.