Bulk scheduling is giving error

Created on 20 June 2025, 4 months ago

Getting error while doing the bulk scheduling
TypeError: strlen(): Argument #1 ($string) must be of type string, array given in strlen() (line 395 of core/lib/Drupal/Component/Utility/Unicode.php)

🐛 Bug report
Status

Active

Version

3.11

Component

Code

Created by

🇮🇳India sakshi@17

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @sakshi@17
  • 🇮🇳India sakshi@17

    Nodes with the long titles are not allowed in Bulk scheduling entity_autocomplete field type.

  • 🇮🇳India sakshi@17

    Ignore patch in comment #3 . It contains extra code.
    Here is the correct patch. I validated the Bulk operation and confirm that it is working as expected now.

  • Issue was unassigned.
  • Pipeline finished with Success
    about 2 months ago
    Total: 372s
    #580922
  • 🇺🇦Ukraine vitaliyb98

    Investigated this error and found that it does not occur in Drupal 11.3. However, the addStatus method expects a string or a MarkupInterface object, whereas in our case, an array is being passed. Even if it works now, there is no guarantee that it will continue to work in the future, since addStatus does not expect an array.

    /**
       * Adds a new status message to the queue.
       *
       * @param string|\Drupal\Component\Render\MarkupInterface $message
       *   The translated message to be displayed to the user. For consistency with
       *   other messages, it should begin with a capital letter and end with a
       *   period.
       * @param bool $repeat
       *   (optional) If this is FALSE and the message is already set, then the
       *   message won't be repeated. Defaults to FALSE.
       *
       * @return $this
       */
      public function addStatus($message, $repeat = FALSE);
    

    Although it works in Drupal 11.3, the code should be updated to match the addStatus method definition. I applied the patch from #5, but replaced the deprecated renderPlain with renderInIsolation.

  • Pipeline finished with Canceled
    about 1 month ago
    Total: 194s
    #595953
  • Pipeline finished with Success
    about 1 month ago
    Total: 171s
    #595955
  • Pipeline finished with Success
    about 1 month ago
    Total: 167s
    #595959
Production build 0.71.5 2024