Uncaught exception with message 'CANNOT_REMOVE_MODULE'

Discussion forum for Extension Writers regarding Extension Development.
Post Reply
User avatar
orynider
Registered User
Posts: 155
Joined: Wed Nov 16, 2005 12:48 pm
Location: Arad, România
Name: Florin Bodin
Contact:

Uncaught exception with message 'CANNOT_REMOVE_MODULE'

Post by orynider » Thu Mar 15, 2018 9:55 am

Hi,

I did added and removed my module several times with no error, but now I get:

Code: Select all

( ! ) Fatal error: Uncaught exception 'phpbb\module\exception\module_exception' with message 'CANNOT_REMOVE_MODULE' in C:\Wamp\www\Rhea\phpbb\module\module_manager.php on line 448
( ! ) phpbb\module\exception\module_exception: CANNOT_REMOVE_MODULE in C:\Wamp\www\Rhea\phpbb\module\module_manager.php on line 448
Call Stack
#	Time	Memory	Function	Location
1	0.0010	156104	{main}( )	...\index.php:0
2	1.5380	8765424	p_master->load_active( )	...\index.php:82
3	1.5450	8884664	acp_extensions->main( )	...\functions_module.php:676
4	1.5600	9035088	phpbb\extension\manager->purge_step( )	...\acp_extensions.php:304
5	1.6350	10136632	phpbb\extension\base->purge_step( )	...\manager.php:359
6	1.6400	10170696	phpbb\db\migrator->revert( )	...\base.php:108
7	1.6400	10170776	phpbb\db\migrator->revert_do( )	...\migrator.php:488
8	1.6400	10171248	phpbb\db\migrator->try_revert( )	...\migrator.php:517
9	1.6400	10177672	phpbb\db\migrator->process_data_step( )	...\migrator.php:554
10	1.6410	10177728	phpbb\db\migrator->run_step( )	...\migrator.php:661
11	1.6420	10178352	call_user_func_array:{C:\Wamp\www\Rhea\phpbb\db\migrator.php:714} ( )	...\migrator.php:714
12	1.6430	10178776	phpbb\db\migration\tool\module->reverse( )	...\migrator.php:714
13	1.6430	10179416	call_user_func_array:{C:\Wamp\www\Rhea\phpbb\db\migration\tool\module.php:454} ( )	...\module.php:454
14	1.6430	10179992	phpbb\db\migration\tool\module->remove( )	...\module.php:454
15	1.6600	10192592	phpbb\module\module_manager->delete_module( )	...\module.php:420
Note that I still can activate the extension. So, should I try to clean up the database manualy?
I use:
Database_Version: MySQL(i) 5.5.24
PHP_VERSION: 5.6.33
phpBB_Forum: 3.2.2

User avatar
Mick
Support Team Member
Support Team Member
Posts: 20125
Joined: Fri Aug 29, 2008 9:49 am
Location: Cardiff

Re: Uncaught exception with message 'CANNOT_REMOVE_MODULE'

Post by Mick » Thu Mar 15, 2018 10:17 am

To receive extension support please visit our Extensions Database and post in the specific extension's designated support area. The link to the support area for each released extension is also available in the first post of each released extension listed in the [3.2.x] Extension Database Releases forum. For extensions still in development (not recommended for a live board) support is in that extensions's topic in the Extensions in Development forum.
"The more connected we get the more alone we become" - Kyle Broflovski

There are no ‘threads’ in phpBB, they are topics.

User avatar
orynider
Registered User
Posts: 155
Joined: Wed Nov 16, 2005 12:48 pm
Location: Arad, România
Name: Florin Bodin
Contact:

Re: Uncaught exception with message 'CANNOT_REMOVE_MODULE'

Post by orynider » Thu Mar 15, 2018 11:09 am

I just started developing this extension and when removing the extension the extension manager query to remove module_id 282 and 283 is ignored as if I dont have privileges to do so.

Since first post I did try to remove them manualy from phpMyAdmin and "DELETE FROM `phpbb_modules` WHERE `phpbb_modules`.`module_id` = 282" is just "Loading" but no delete is not working.

Maybe I do a fresh install and try again.

User avatar
orynider
Registered User
Posts: 155
Joined: Wed Nov 16, 2005 12:48 pm
Location: Arad, România
Name: Florin Bodin
Contact:

Re: Uncaught exception with message 'CANNOT_REMOVE_MODULE'

Post by orynider » Thu Mar 15, 2018 12:40 pm

I found the problem that caused the error.

I updated migrations/module*_data.php file 'modes' => array() list, but did not upgraded also \acp\module*_info.php 'modes' => array().

I solved by exporting table phpbb_modules to a phpbb_modules_new.sql file and after importing the clean file removing the extension from ACP and enabling the extension with both PHP files updated. :D

Post Reply

Return to “Extension Writers Discussion”

Who is online

Users browsing this forum: No registered users and 23 guests