Twig_Error_Syntax: {% trans %} error in system-modules-uninstall.html.twig

Created on 23 March 2018, over 6 years ago
Updated 11 July 2024, about 2 months ago

The website encountered an unexpected error. Please try again later.</br></br><em class="placeholder">Twig_Error_Syntax</em>: The text to be translated with &quot;trans&quot; can only contain references to simple variables in <em class="placeholder">Twig_Extensions_TokenParser_Trans-&gt;checkTransString()</em> (line <em class="placeholder">46</em> of <em class="placeholder">core/themes/stable/templates/admin/system-modules-uninstall.html.twig</em>).

🐛 Bug report
Status

Postponed: needs info

Version

11.0 🔥

Component

Stable 9 theme

Created by

🇨🇦Canada steve.m

Live updates comments and jobs are added and updated live.
  • Needs issue summary update

    Issue summaries save everyone time if they are kept up-to-date. See Update issue summary task instructions.

  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇳🇿New Zealand quietone New Zealand

    Moving remaining issues for 'Stable theme' to 'Stable 9 theme' based on #3332485-5: [Meta] Stable issue triage by markconroy.

  • Status changed to Postponed: needs info about 2 months ago
  • 🇮🇪Ireland markconroy

    I don't think this is an issue any more.

    After installing standard profile, I tried the following tests:

    1. Set stable9 as my admin theme, uninstall contact module (via UI). No errors reported.
    2. Set stable9 as my admin theme and default theme, uninstall contact module (via UI). No errors reported.
    3. Set stable9 as my admin theme and default theme, uninstall Claro and Olivero so only stable9 was left enabled, uninstall contact module (via UI). No errors reported.

    If this is still an issue, we will need an updated issue summary and steps to reproduce.

    If this is still an issue, I suggest instead of removing this line
    The following reason prevents {{ module.module_name }} from being uninstalled:

    We look to set {{ module.module_name }} to be a simple variable, so just inside the {% for %}, something like this:

    {% for module in modules %}
      {% set module_name = module.module_name %}
    {% endfor %}
    

    ===
    Thanks to Code Enigma for sponsoring my time to work on this.

  • 🇮🇪Ireland markconroy

    Also, the patches we have for this so far are for stable and stable9, but stable is not part of Drupal core any more. So at a very minimum we need to update those to refer to stable9 only.

Production build 0.71.5 2024