After installing breakpoints beta 2 and resp_img beta 2, I get the following error when I go to the settings pages for responsive images:

Warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'resp_img_admin_settings' was given in drupal_retrieve_form() (line 795 of /includes/form.inc).

Comments

attiks’s picture

Strange, it is no longer in the 7.x-2.x version, was resp_img 7.x-1.x installed before? If so did you uninstall it, because there's no upgrade path (for the moment)

rainbowarray’s picture

That's probably the issue. I'll uninstall and then reinstall.

rainbowarray’s picture

There needs to be a warning on the main page about installing 2.x. I uninstalled resp_img, then tried reinstalling 2.x. Same problem. Uninstalled. Reuploaded 1.3. Tried to uninstall. Wasn't able to do so. (It doesn't look as if there is an uninstall function.) Manually deleted the resp_images_suffix table. Reinstalled 2.x. Now I am still getting the same error as before.

attiks’s picture

Project page already says: "This is a complete rewrite, do not try to upgrade from 7.x-1.x to 7.x-2.x, this will not work and break your site"

Did you clear all caches,? or do you have a copy somewhere else?

Can you do a find on the file system to look for any file containing resp_img_admin_settings
grep -r resp_img_admin_settings * on linux / command line

Marked #1706592: Undefined index as duplicate

rainbowarray’s picture

Getting White Screen of Death when trying to clear cache. When I enable error reporting, I get the following:

Fatal error: Class 'RespImgPageCache' not found in /includes/cache.inc on line 31

rainbowarray’s picture

So RespImgPageCache is defined in 1.3 in the cache.inc file. Clearly there is some holdover lingering even though I've done my best to purge 1.3 from the system. Any suggestions on how to get rid of this?

rainbowarray’s picture

From my reading, the basic problem is that RespImgPageCache needs to be removed from the registry. I've been unable to rebuild the registry, and I haven't been able to find a way to manually remove this from the registry. Any suggestions?

attiks’s picture

You can try downloading 7.x-1.x and extracting the cache.inc file to the resp_img folder, it assume it will work again.
Try clearing your cache using drush (drush cc all) and if all goes well
Delete the variable (drush vdel cache_class_cache_page -y) and clear cache again (drush cc all)

If that fails have a look at registry_rebuild

All the above should have happened when you uninstalled 7.x-1.x version, but I'll try to reproduce it to see what's going on.

attiks’s picture

I did some more testing, the caching variable is reset the moment you disable resp_img 7.x-1.x, so try deleting the record 'cache_class_cache_page' from the variable table.

rainbowarray’s picture

Clearing cache and registry rebuild didn't work, nor did deleting cache_class_cache_page from the variable database. To fix this, I ended up having to restore the database.

One I restored to before I installed 2.x, I was able to uninstall 1.3, then install 2.x, without any registry errors or caching problems.

attiks’s picture

Status: Active » Closed (cannot reproduce)

Let's hope it doesn't happen again :/

jelle_s’s picture

If it does just execute this peace of code (in devel/php). I had the same error when upgrading from 7.x-1.x to 7.x-2.x (because there is no upgrade path yet):

  $cache_class_cache_page_old = variable_get('resp_img_cache_class_cache_page_old');
  if (isset($cache_class_cache_page_old)) {
    variable_set('cache_class_cache_page', $cache_class_cache_page_old);
  }
  else {
    variable_del('cache_class_cache_page');
  }
  variable_del('resp_img_cache_class_cache_page_old');
marcoka’s picture

#12 works great for this problem.

jelle_s’s picture

Status: Closed (cannot reproduce) » Fixed

Upgrade from 1.x to 2.x

There now is an upgrade path from 1.x to 2.x.

To upgrade, follow these steps:

  1. Disable Responsible images and styles (do not uninstall) (you need to do this because we don't use the custom cache class in 2.x anymore. Related: #1706596: Invalid callback)
  2. Download Breakpoints, CTools and Field formatter settings.
  3. Enable Responsible images and styles again (along with its requirements Breakpoints, CTools and Field formatter settings).
  4. Go to /update.php and follow the steps.
  5. And you're done!

Status: Fixed » Closed (fixed)

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

generalredneck’s picture

Issue summary: View changes
Status: Closed (fixed) » Needs review
StatusFileSize
new1.44 KB

I know this has been closed as "fixed" but I found the update process a little too "manual" for Promet's taste. With that said, I've developed a patch that will allow you to apply the patch to 2.0-beta3 and move on with without having to disable or turn on anything... All that is required is that you have the correct modules downloaded and update hook 7200 takes care of the rest.

Here is my typical update process

echo "Initial Update so updated modules can work."
$drush updb -y
echo "Rebuilding registry and clearing caches.";
$drush rr
echo "Enabling modules";
$drush en $(echo $DROPSHIP_SEEDS | tr ':' ' ')

Removed the files[] entry as well because we don't necessary need to load the .module file as it is pretty much always loaded when we need it.

generalredneck’s picture

Version: 7.x-2.0-beta2 » 7.x-2.x-dev
StatusFileSize
new1.01 KB

Adding a patch here for 7.x-2.x since the above was for beta-3. Turns out there are a crap ton of fixes made between dev and beta3.

generalredneck’s picture

Actually had an issue with my patch needing to run before another module that calls cache_clear_all() so added that to the dependencies list.

tvm100’s picture

I have this module but when I disable it (to ultimately remove it), I receive the same error as mdrummond (#5):

Fatal error: Class 'RespImgPageCache' not found in /home/myaccount/public_html/mysite/includes/cache.inc on line 31

What is recommended to completely remove this module (not upgrade) and eliminate the error?

I have tried clearing cache, rebuilding registry, and the code in #12.