Missing requirements message should not be translatable

Created on 30 January 2022, almost 3 years ago
Updated 14 August 2024, 4 months ago

Problem/Motivation

This is a follow-up to #2321609: Provide a helpful message in case requirements are not met โ†’ , see this comment โ†’ from @dawehner:

Given that the requirements for example are in english anyway did you thought of dropping the translatablity here? For sure this would be out of scope, just asking.

Here is a typical usage of RequirementsException:
throw new RequirementsException('The module comment is not enabled in the source site');

This message is always in English, hence it doesn't make to translate a string, where this message is being injected.

It was discovered while looking at #3254986: Remove requirements array from RequirementsException message โ†’ , so let's wait until it lands.

Proposed resolution

Remove translate function (t) from this message:

$this->message->display(
        $this->t(
          'Migration @id did not meet the requirements. @message @requirements',
          [
            '@id' => $this->migration->id(),
            '@message' => $e->getMessage(),
            '@requirements' => $e->getRequirementsString(),
          ]
        ),
        'error'
      );

Remaining tasks

todo

๐Ÿ“Œ Task
Status

Needs work

Version

11.0 ๐Ÿ”ฅ

Component
Migrationย  โ†’

Last updated 3 days ago

Created by

๐Ÿ‡บ๐Ÿ‡ฆUkraine Matroskeen ๐Ÿ‡บ๐Ÿ‡ฆ Ukraine, Lutsk

Live updates comments and jobs are added and updated live.
  • Novice

    It would make a good project for someone who is new to the Drupal contribution process. It's preferred over Newbie.

Sign in to follow issues

Merge Requests

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
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia prem suthar Ahemdabad- Gujrat , Jodhpur - Rajsthan

    Prem Suthar โ†’ made their first commit to this issueโ€™s fork.

  • Pipeline finished with Success
    5 months ago
    Total: 532s
    #228889
  • Status changed to Needs review 5 months ago
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia prem suthar Ahemdabad- Gujrat , Jodhpur - Rajsthan
  • Status changed to RTBC 5 months ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Seems straightforward

    But again this was tagged novice and 24 hours later picked up. Novice tag is meant for new users, @Prem Suthar looking at your post history that would not appear to be you. Please avoid newly tagged novice issues.

    If its tagged and sits there for 2-3 weeks with no movement then fair game.

  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia bilalshaikh292

    Hello, I am new to the community. I reached here by reading many documents. I am very new to Drupal and currently finding my first issue to work on. I saw the Novice Tag and found this issue as a good point to start with. Can I contribute to this issue. And Also if there is any more simpler issue to work on as a fresher.Looking forward to some help and support.Thanks

  • Status changed to Needs work 4 months ago
  • ๐Ÿ‡ณ๐Ÿ‡ฟNew Zealand quietone

    While this is a simple fix it does need a comment because it is unique.

    @bilalshaikh292, Welcome to Drupal! Thanks for searching the queue for issues to work on. This status of this issue is "Reviewed & tested ...' so the next step here is final review and commit. It would be better to look for issues with a status of 'Active' or 'Needs Work' to start with. There is more help about contributing in Contributor guide โ†’ .

  • ๐Ÿ‡ช๐Ÿ‡ธSpain briantes

    The issue should be closed. I don't know any reason why it shouldn't be translatable.

  • ๐Ÿ‡ช๐Ÿ‡ธSpain briantes

    We review the ticket and recommend that we should not be fixing this issue in consideration with the international community that speaks multiple languages.

    The community has aggree to support core in multiple languages for clients and developers as well. We do not see any reason why this specific message should make any exception.

    As an alternative, site administrators can use configuration to disable translations alert messages for specific user roles.

Production build 0.71.5 2024