Magento 1 – Fixing Autoloader Trying to Load Deleted Modules

cachemodule

I've removed a module:

  • Deleted the files under app/code/community
  • Deleted the xml file from app/etc/modules
  • Removed the entry from the core_resource table
  • Deleted all entries under app/design that relate to the module
  • Deleted all files under var/cache

Below is the error I'm getting that is stopping me from accessing any interface for the site.

Warning: include(Pulsestorm/Better404/Model/Observer.php): failed to open stream: No such file or directory  in /var/www/vhosts/mysite.co.uk/httpdocs/releases/20141009070627/lib/Varien/Autoload.php on line 93

Best Answer

The only way a class would attempt to be loaded would be,

  1. The mode is enabled
  2. The config.xml for the file still exists
  3. The config cache has not been refreshed
  4. Compiler is enabled and not rebuilt following module removal
  5. Another class extends /rewrites the class (check var/ait...)
  6. Another class is loading the class by name (in this case it would look in Mage/... - so not the case)

Given your directory structure contains different releases, it sounds like you've deleted the wrong files in the wrong folder by mistake.

That, or you aren't using file based caching, so removing var/cache has had no effect and that you need to empty whatever you defined in your local.xml.

If you are using Aitoc modules, they auto rewrite and cache in var/ait - you can remove this folder safely.

Related Topic