Missing image breaks zip

Created on 11 June 2025, about 1 month ago

I came across a situation during an export where a file used in a referenced image entity wasn't in the file system. This caused an error in the creation of the zip file, by putting this right in the front of its saved output:

: file_get_contents(public://file_subdir/my_file.jpg): Failed to open stream: "Drupal\Core\StreamWrapper\PublicStream::stream_open" call failed in on line

The zip file does get created and saved, but has "bad format". I presume if I had all error display off, this wouldn't happen, but that's not something to count on.

I offfer the attached small patch, which seems to be working for me.

πŸ› Bug report
Status

Active

Version

1.4

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States datawench

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

Comments & Activities

Production build 0.71.5 2024