Start with a clean D7 HEAD install. Activate forum.module, then immediately deactivate it and uninstall it.
forum.module appears to have uninstalled fine. But then if you go and switch forum.module back on, you get this error message:
FieldException: Attempt to create field name <em>taxonomy_forums</em> which already exists and is active. in field_create_field() (line 255 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
And the screen looks like the first attached screenshot.
Go back to the site's root, and it displays fine. Go to admin/config/modules and forum.module is activated. It appears to deactivate fine. But go to uninstall it and you get the following errors:
* Notice: Undefined index: machine_name in taxonomy_vocabulary_delete() (line 336 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/taxonomy/taxonomy.module).
* Notice: Undefined index: field_name in field_delete_instance() (line 861 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
* Notice: Undefined index: object_type in field_delete_instance() (line 862 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
* Notice: Undefined index: bundle in field_delete_instance() (line 863 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
* Notice: Undefined index: field_name in field_delete_instance() (line 867 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
* Notice: Undefined index: field_name in field_delete_instance() (line 861 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
* Notice: Undefined index: object_type in field_delete_instance() (line 862 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
* Notice: Undefined index: bundle in field_delete_instance() (line 863 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
* Notice: Undefined index: field_name in field_delete_instance() (line 867 of /Applications/XAMPP/xamppfiles/htdocs/drupal7/modules/field/field.crud.inc).
For the full screen at this point, see the second attached screenshot.
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | update2-619904-forum-module-uninstall-issue.patch | 1.44 KB | Anonymous (not verified) |
| #5 | updated-619904-forum-module-uninstall-issue.patch | 1.43 KB | Anonymous (not verified) |
| #3 | 619904-forum-module-uninstall-issue.patch | 1.43 KB | Anonymous (not verified) |
| Screenshot2.png | 185.5 KB | jim0203 | |
| Screenshot1.png | 84.21 KB | jim0203 |
Comments
Comment #1
brianV commentedI got errors while uninstalling forum.moudle as well. ALthough different from those in the initial post:
Comment #2
catchHmm, interesting one. There's currently nothing stopping people adding the forum field to bundles and using it for other purposes, and in D6 we don't delete the forum vocabulary either afaik. So probably there needs to be a 'create field if it doesn't exist' check in forum_install().
Comment #3
Anonymous (not verified) commentedI think i nailed it, it now keeps the taxonomy and the variable "forum_nav_vocabulary" after uninstall. And checks for the taxonomy_forums field on install.
Comment #4
chx commentedAlmost great but you need spaces on both sides of the = sign. (Yes. Drupal is VERY picky on its code style http://drupal.org/coding-standards )
Comment #5
Anonymous (not verified) commentedHere it is with the spaces.
Comment #6
catchTwo more nitpicks:
$fieldcheck- we don't munge words together, so this would be$field_checkAlso
+ // Create fields if info on "taxonomy_forums" field turns out emptyshould end with a period/full stop.
Otherwise looks RTBC.
Comment #7
Anonymous (not verified) commentedFixed issues catch mentioned.
Comment #8
catchLovely! (please wait for test bot before commit).
Comment #9
dries commentedCommitted to CVS HEAD. Thanks.