Various PHP warnings appear when updating between minor versions:

1)

Warning: class_implements() [function.class-implements]: Class ImageCacheActionsModuleStreamWrapper does not exist and could not be loaded in file_get_stream_wrappers() (line 136 of drupal/includes/file.inc).

2)

Warning: in_array() [function.in-array]: Wrong datatype for second argument in file_get_stream_wrappers() (line 136 of drupal/includes/file.inc).

3)

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in image_styles() (line 576 of drupal/modules/image/image.module).

Comments

vthirteen’s picture

same here:

    Warning: class_implements() [function.class-implements]: Class ImageCacheActionsModuleStreamWrapper does not exist and could not be loaded en file_get_stream_wrappers() (línea 136 de /home/mywebsite/public_html/includes/file.inc).
    Warning: in_array() [function.in-array]: Wrong datatype for second argument en file_get_stream_wrappers() (línea 136 de /home/mywebsite/public_html/includes/file.inc).
fietserwin’s picture

This indicates that you need to refresh the registry. A clear all caches should do so. I'm not sure that the array_merge warning also has this cause, but assume that it is due to the earlier errors.

Can you let me know if the error persists after clearing the registry cache?

CinemaSaville’s picture

The first two are gone, but as you suspected the array merge warning still remains. Any ideas for a fix.

CinemaSaville’s picture

The first two are gone, but as you suspected the array merge warning still remains. Any ideas for a fix.

fietserwin’s picture

I had similar messages today when doing some testing:

    Warning: Division by zero in theme_image_style_preview() (line 786 of modules\image\image.admin.inc).
    Warning: array_intersect_key(): Argument #1 is not an array in theme_image_style_preview() (line 788 of modules\image\image.admin.inc).

But this occurred with effects that failed to apply successfully. So I suspect it is a style/effect specific issue. Are you using custom actions? If so, you need to run update.php and please read the README.txt of the custom actions submodule about manual changes to the code you write.

If that does not help can you list the image style here, preferably as an array dump. you can create that using features.

CinemaSaville’s picture

I'm using this module http://drupal.org/project/video_embed_field_overlay So I'm sure that's the culprit. Unfortunately, I'm not sure how to fix it. I should probably post the issue in that queue since that's where it belongs, but if you have any ideas let me know. Thanks again.

fietserwin’s picture

This could very well be so. I have changed the way to specify files in a non backwards compatible way. You should now use:

either 1 of the enabled scheme's:
- public://
- private:// (preferred for site specific masks, overlay's etc that do not need to be shared publicly))
- module://{module_name}/{resource-name} (introduced by imagecache_actions module, and the reason for your first 2 warnings) ( preferred for module provided resources, like the button overlay of the mentioned module)
- temporary:// (unlikely to be useful, but supported anyway)

or a relative (to current directory, probably Drupal root) or absolute path.

I explicitly chose to do this in a non-backwards compatible way as there is now a multitude of possible locations (compared to only the public directory in D6) and there should be no confusion about what file will be taken from what location.

CinemaSaville’s picture

Status: Active » Fixed

I actually turned off the test actions module and it looks like it cleared up for now. Don't know why that was turned on. So for now I'm going to set this as fixed. If it comes back, I'll try your fix. Thanks for the help.

fietserwin’s picture

I did not yet have a look at the test suite. I'm afraid it is still mostly D6 based. We do have plans to set up a good test suite, as we also have plans for large refactorings. So a good test suite will be needed.

I will either remove it for 1.0 or have another look at it before 1.0. Thanks for reporting.

fietserwin’s picture

Created issue #1593246: Update to imagecache_actions 7.x-1.0 as a follow up to this issue.

Status: Fixed » Closed (fixed)

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

jenlampton’s picture

Issue summary: View changes

code tags and non-warning text added

jenlampton’s picture

Issue summary: View changes

numbers

jenlampton’s picture

Version: 7.x-1.0-alpha1 » 7.x-1.0
Status: Closed (fixed) » Active

Unfortunately this issue is not fixed, I'm still getting errors 1 & 2 when updating from the 7.x-0.0 version to 7.x-1.0.
reopening for maintainer's attention.

fietserwin’s picture

Status: Active » Fixed

As I see it, it is not an issue. You install the new version and before the new classes can be registered, they are already (attempted to be) instantiated (because registration and discovery work differently). So clear the registry cache and the error messages will be gone. If not, please re-reopen this issue, detailing again what messages you get and when.

Note that issue #1702716: System Stream Wrappers Conflict is kind of related and will resolve the issue in a next version.

Status: Fixed » Closed (fixed)

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

Anonymous’s picture

Issue summary: View changes

remove path stuff