Problem/Motivation

Seeing this when saving files on Acquia.

Adding DependencySerializationTrait to the event subscriber cures.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

EthanT created an issue. See original summary.

ethant’s picture

StatusFileSize
new1.2 KB
ethant’s picture

StatusFileSize
new1.67 KB
ethant’s picture

StatusFileSize
new743 bytes
ethant’s picture

StatusFileSize
new3.05 KB
ethant’s picture

StatusFileSize
new3.52 KB
ethant’s picture

StatusFileSize
new4.11 KB
ethant’s picture

StatusFileSize
new5.22 KB
ethant’s picture

StatusFileSize
new7.25 KB
ethant’s picture

StatusFileSize
new7.47 KB
ethant’s picture

j-barnes made their first commit to this issue’s fork.

j-barnes’s picture

@ethan - Great find, it looks like mpdf needed to have the temp location explicitly set to avoid having it use the vendor location which was causing permission issues on certain environments like Acquia Platform. This lead to a serialization error because the logger function was trying to print out the entire exception.

I've updated the logger to use $e->getMessage() and now pull in the temp location via filesystem and have also cleaned up some of the types.

Thanks again, going to leave this open for a bit for testing.

j-barnes’s picture

Status: Active » Needs review
j-barnes’s picture

Unfortunately it looks like mPDF uses FPDI which does not work on PDFs above v1.4 (at least the free version). Updating MR to use GhostScript instead which should have increased performance and works on 1.7+.

sunny-lee’s picture

Status: Needs review » Reviewed & tested by the community

PDF metadata patches and modules works with Drupal 10 and PHP 8.1

j-barnes’s picture

  • j-barnes committed 4a3cdf9e on 1.0.x
    Issue #3368688: LogicException: Settings can not be serialized.
    
j-barnes’s picture

Status: Reviewed & tested by the community » Fixed
j-barnes’s picture

Status: Fixed » Closed (fixed)