backdrop-contrib / d2b_migrate

GNU General Public License v2.0
5 stars 6 forks source link

Deprecated function: realpath() #60

Open stpaultim opened 2 months ago

stpaultim commented 2 months ago

I'm getting this error at the upgrade stage. Any ideas on how to debug this or get past it?

NOTE: For this upgrade, I ran into the "Langcode" issue so I followed the steps outlined by @irinaz here: https://github.com/backdrop-contrib/d2b_migrate/issues/45#issuecomment-2105105318

But, I got this message.

Deprecated function: realpath(): Passing null to parameter #1 ($path) of type string is deprecated in BackdropLocalStreamWrapper->getLocalPath() (line 380 of /var/www/html/core/includes/stream_wrappers.inc).

image

irinaz commented 2 months ago

This is new issue, I have not seen it before. Also not sure why css directory is not writable.

sikofitt commented 2 months ago

Passing null to non-nullable arguments was deprecated in PHP v8.1 https://wiki.php.net/rfc/deprecate_null_to_scalar_internal_arg.

This looks like it should be a backdrop fix for whatever is happening in the stream wrapper. But also probably in d2b to make sure null doesn't get passed to the stream wrapper. Perhaps this is caused by the css injector directory not being writable?

Not the right solution but you can turn off deprecation errors and see if it works by adding ~E_DEPRECATED to error_reporting.