I downloaded features-7.x-1.0-beta5 and tried to activate it resulting in a fatal error. Here is my error.log:

[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP Fatal error: Call to undefined function ctools_features_declare_functions() in /var/www/workspace/drupal-full/sites/all/modules/features/features.module on line 319, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP Stack trace:, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 1. {main}() /var/www/workspace/drupal-full/index.php:0, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 2. menu_execute_active_handler() /var/www/workspace/drupal-full/index.php:21, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 3. call_user_func_array() /var/www/workspace/drupal-full/includes/menu.inc:503, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 4. drupal_get_form() /var/www/workspace/drupal-full/includes/menu.inc:0, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 5. drupal_build_form() /var/www/workspace/drupal-full/includes/form.inc:123, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 6. drupal_prepare_form() /var/www/workspace/drupal-full/includes/form.inc:330, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 7. drupal_alter() /var/www/workspace/drupal-full/includes/form.inc:1056, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 8. features_form_system_modules_alter() /var/www/workspace/drupal-full/includes/module.inc:1017, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 9. features_rebuild() /var/www/workspace/drupal-full/sites/all/modules/features/features.module:740, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 10. _features_restore() /var/www/workspace/drupal-full/sites/all/modules/features/features.module:816, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&
[Fri Dec 23 18:41:44 2011] [error] [client 127.0.0.1] PHP 11. features_include() /var/www/workspace/drupal-full/sites/all/modules/features/features.module:748, referer: http://drupal-full.localhost/?q=admin%2Fconfig%2Fdevelopment%2Fperformance&

What was committed?

Comment #8 by @febbrary, based on patch in #5.
e894439 Issue #1382156 by tim.plunkett | davidn: Fixed PHP Fatal error: Call to undefined function ctools_features_declare_functions()

CommentFileSizeAuthor
#5 features-1382156-5.patch565 bytestim.plunkett

Comments

Noe_’s picture

I noticed this bug report because I wanted to find a solution to this exact problem, however I saw that there was a "needs reviews" status here.

So I wanted to provide people with the steps needed to reproduce this bug. Thus here are the steps to reproduce it, kinda:

1. Download a Drupal tarball.
2. Extract and install it.
3. Download the Features module.
4. Enable the features module.

At this time I get a blank screen, and not the "Fatal error: Call to undefined function ctools_features_declare_functions()" message I expected.

But when I go to the command line and type:
drush dis features

And then go to the modules page it works again.
So now I type (in the command line)
drush en features

and then I get the following message:
noe@noe-desktop:/www/example$ drush en features
The following extensions will be enabled: features
Do you really want to continue? (y/n): y
PHP Fatal error: Call to undefined function ctools_features_declare_functions() in /www/example/sites/all/modules/features/features.module on line 319
Drush command terminated abnormally due to an unrecoverable error. [error]
Error: Call to undefined function ctools_features_declare_functions()
in /www/example/sites/all/modules/features/features.module, line 319

There we have it again.

So I hope this example will you to reproduce this error, and have this bug confirmed. Because it is a problem for me too.

anderidder’s picture

I have same probleme error:
Fatal error: Call to undefined function ctools_features_declare_functions() in D:\wamp\www\eSpecification\sites\all\modules\_features\features.module on line 319
After the install Features 7.x-1.0-beta5
http://drupal.org/project/features
I use drupal core 7.9.

And now can i not the modules for activate of uninstall?
Can anybody help me for this module deactivate it?

I learn now cms-tool Drupal.

Can you find this probleme.

I thank before.

Greeting Anja

peterMankato’s picture

I discovered that if I update the Module: ctools http://drupal.org/project/ctools this fixes this problem.

tim.plunkett’s picture

Status: Needs review » Active

Needs review implies there is a patch.

tim.plunkett’s picture

Status: Active » Needs review
StatusFileSize
new565 bytes
hefox’s picture

Applies clean and looks like it should fix it (haven't disabled ctools to make absolutely sure it fixes the issue)

tim.plunkett’s picture

Assigned: Unassigned » febbraro
Status: Needs review » Reviewed & tested by the community

I was able to disable ctools and not have fatals.

There now needs to be a new beta after this patch, any contrib module with a dependency on features will fail simpletest until then.

See http://qa.drupal.org/pifr/test/208758

febbraro’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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

donquixote’s picture

Issue summary: View changes