LogicException: Settings can not be serialized

Created on 2 April 2025, 3 days ago

Problem/Motivation

My batch operation works great and runs as expected in my local, but it breaks after I pushed up to my dev environment on Acquia. I also tried running the included batch operations (TestDo10ThingsOnlyOnce, etc). I'm getting this error in Drupal logs when I Run operation now:
LogicException: Settings can not be serialized. This probably means you are serializing an object that has an indirect reference to the Settings object. Adjust your code so that is not necessary. in Drupal\Core\Site\Settings->__sleep() (line 90 of /var/www/html/docroot/core/lib/Drupal/Core/Site/Settings.php).

Steps to reproduce

I can't reproduce this on a clean install because it doesn't throw the error on my local.

I'm on the latest 1.0.12 version with core 10.4.5 and php 8.3.15

πŸ› Bug report
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States capysara

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

Merge Requests

Comments & Activities

Production build 0.71.5 2024