I disabled profile2 and received the following error:

Fatal error: Class 'Profile2MetadataController' not found in /home/unitedor/public_html/sites/all/modules/entity/entity.info.inc on line 23

I'm unable to access my site due to this error. Any ideas on how to fix?

Phil

Comments

pgglass’s picture

I opened "entity.info.inc" and disabled lines 23 & 24. I was then able to access the web site. I re-enabled the Profile2 module and went back to "entity.info.inc" and re-enabled lines 23 & 24. Is there a way to fix this so I can remove the Profile2 module? Do I have to remove the fields applied to the module before I can disable the module?

Morten Najbjerg’s picture

Subscribe

Patroclas’s picture

This seems to be the same issue as http://drupal.org/node/1416420

Any progress on a fix for this? I don't want to upload my dev site with a module I don't need that includes a fatal time-bomb until this is fixed.

I wish I could help, but I'm not a coder.

defunctcitizen’s picture

  1. Comment out the problematic lines (23 & 24 in entity.info.inc for me)
  2. Disable Profile2 (/admin/modules)
  3. Uninstall Profile2 (/admin/modules/uninstall)
  4. Delete the module's files
  5. Uncomment the entity lines and clear cache

Worked for me!

fago’s picture

Status: Active » Postponed

Manually clearing 'cache' tables should help too, see http://drupal.org/node/1325126

I'm setting this to postponed so it is visible in the profile2 queue too.

Patroclas’s picture

I used the procedure in #4 on my dev site. It has worked, but there were some problems. I got a WSOD after disabling the Profile pages sub-module but got back to the site by using the back button in my browser. Clearing cache from the admin UI also threw some errors. I have not yet tried manually clearing cache tables as suggested by fago, but it looks as if that's essential.

I also have the Profile2 (now unused) on my production site and I will not be disabling it until I am sure there is a robust solution.

I would not advise anyone to install Profile2 at this time unless they are sure that they will want to keep it. In my case, I have discovered that with a combination of content-types, role permissions and per-role blocks, Profile2 is not needed. Maybe this is unfair as the error appears to be related to core entity module (?) - but that's my opinion at this time.

socialnicheguru’s picture