Problem/Motivation

I'm getting this PHP warning on articles containing media entities.

Warning: Undefined array key "0770" in Twistor\Flysystem\Plugin\Stat->mergeMeta() (line 157 of vendor/twistor/flysystem-stream-wrapper/src/Flysystem/Plugin/Stat.php).

In this flysystem plugin, it's expecting a "visibility" of a code that corresponds to either "public" or "private". Instead of one of those, the files have a visibility of 0770, which apparently in some file systems is used as a "custom" file permission which then can have further handling done. So I added a line that says if it's 0770 then we're going to say it's "public" (because these files should be public).

This doesn't seem like an ideal solution, but it does prevent the warning. If anyone has a better solution or thoughts on what causes it, I'd love to hear them.

Steps to reproduce

I'm actually not sure if this is particular to our environment. This occurs on Pantheon environments using flysystem_s3.

Upgrade to PHP 8.1. Create a node that has a media item attached that uses flysystem_s3.

Comments

Laura Johnson created an issue. See original summary.

ltrain’s picture

StatusFileSize
new560 bytes
geoanders’s picture

Status: Active » Needs review
lisa.rae’s picture

Version: 8.x-1.x-dev » 2.1.x-dev
lisa.rae’s picture

Status: Needs review » Needs work
lisa.rae’s picture

Version: 2.1.x-dev » 3.0.x-dev
Status: Needs work » Postponed

Postponing to 3.0, likely will not be needed as the dependency on twistor/flysystem-stream-wrapper will no longer be present.

lisa.rae’s picture

Status: Postponed » Fixed

Fixed in release 2.3

lisa.rae’s picture

Updating issue for attribution

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.