ComboStrap / combo

Dokuwiki Combo Plugin. Making Web Publication a Breeze
https://combostrap.com
GNU General Public License v2.0
14 stars 4 forks source link

TypeError: call_user_func_array(): Combo to Sqlite to DW error trace #113

Open jkiser99dev opened 1 month ago

jkiser99dev commented 1 month ago

Greetings again!

I'm not sure if this sort of thing goes under Issues or Discussions.

A user just reported this dokuwiki error, originating from ComboStrap. The only thing on 2 pages where this occurs that I see as odd is that they immediately start with: ====topic==== and the missing method is list_open.

ERROR: TypeError: call_user_func_array(): Argument #1 ($callback) must be a valid callback, class Doku_Renderer_metadata does not have a method "list_open"

(Running sqlite3 v3.7.17, php 8.1)

LOGS: (fyi - has-motion.com/wiki is a migration testing setup) 2024-06-07 12:47:21 /home/hasmotinc/public_html/wiki/lib/plugins/sqlite/SQLiteDB.php(445) PDOException: SQLSTATE[HY000]: General error: 1 near "DROP": syntax error

0 /home/hasmotinc/public_html/wiki/lib/plugins/sqlite/SQLiteDB.php(445): PDO->exec('ALTER TABLE ali...')

1 /home/hasmotinc/public_html/wiki/lib/plugins/sqlite/SQLiteDB.php(83): dokuwiki\plugin\sqlite\SQLiteDB->applyMigrations()

2 /home/hasmotinc/public_html/wiki/lib/plugins/data/helper.php(92): dokuwiki\plugin\sqlite\SQLiteDB->__construct('data', '/home/hasmotinc...')

3 /home/hasmotinc/public_html/wiki/lib/plugins/data/action.php(57): helper_plugin_data->getDB()

4 /home/hasmotinc/public_html/wiki/inc/Extension/EventHandler.php(80): action_plugin_data->handle(Object(dokuwiki\Extension\Event), NULL)

5 /home/hasmotinc/public_html/wiki/inc/Extension/Event.php(75): dokuwiki\Extension\EventHandler->process_event(Object(dokuwiki\Extension\Event), 'BEFORE')

6 /home/hasmotinc/public_html/wiki/inc/Extension/Event.php(133): dokuwiki\Extension\Event->advise_before(false)

7 /home/hasmotinc/public_html/wiki/inc/Extension/Event.php(200): dokuwiki\Extension\Event->trigger('_io_writeWikiPa...', false)

8 /home/hasmotinc/public_html/wiki/inc/io.php(217): dokuwiki\Extension\Event::createAndTrigger('IO_WIKIPAGE_WRI...', Array, '_io_writeWikiPa...', false)

9 /home/hasmotinc/public_html/wiki/inc/File/PageFile.php(276): io_writeWikiPage('/home/hasmotinc...', '**HAS-Motion, I...', 'start', 1717764441)

10 /home/hasmotinc/public_html/wiki/inc/File/PageFile.php(189): dokuwiki\File\PageFile->saveOldRevision()

11 /home/hasmotinc/public_html/wiki/inc/common.php(1300): dokuwiki\File\PageFile->saveWikiText('**HAS-Motion, I...', 'Ensured that Vi...', true)

12 /home/hasmotinc/public_html/wiki/inc/Action/Save.php(58): saveWikiText('start', '**HAS-Motion, I...', 'Ensured that Vi...', true)

13 /home/hasmotinc/public_html/wiki/inc/ActionRouter.php(86): dokuwiki\Action\Save->preProcess()

14 /home/hasmotinc/public_html/wiki/inc/ActionRouter.php(49): dokuwiki\ActionRouter->setupAction('save')

15 /home/hasmotinc/public_html/wiki/inc/ActionRouter.php(62): dokuwiki\ActionRouter->__construct()

16 /home/hasmotinc/public_html/wiki/inc/actions.php(19): dokuwiki\ActionRouter::getInstance(true)

17 /home/hasmotinc/public_html/wiki/doku.php(131): act_dispatch()

18 {main}

2024-06-07 12:50:17 /home/hasmotinc/public_html/wiki/lib/plugins/combo/ComboStrap/EditButton.php(269) E_WARNING: Undefined array key "name"

0 /home/hasmotinc/public_html/wiki/lib/plugins/combo/ComboStrap/EditButton.php(269): dokuwiki\ErrorHandler::errorHandler(2, 'Undefined array...', '/home/hasmotinc...', 269)

1 [internal function]: ComboStrap\EditButton::ComboStrap{closure}(Array)

2 /home/hasmotinc/public_html/wiki/lib/plugins/combo/ComboStrap/EditButton.php(332): preg_replace_callback('/<!--\s*EDIT({....', Object(Closure), '<section class=...')

3 /home/hasmotinc/public_html/wiki/lib/plugins/combo/ComboStrap/EditButton.php(141): ComboStrap\EditButton::replaceAll('<section class=...')

4 /home/hasmotinc/public_html/wiki/lib/plugins/combo/ComboStrap/FetcherMarkup.php(804): ComboStrap\EditButton::replaceOrDeleteAll('<section class=...')

5 /home/hasmotinc/public_html/wiki/lib/plugins/combo/ComboStrap/TemplateForWebPage.php(598): ComboStrap\FetcherMarkup->getFetchString()

6 /home/hasmotinc/public_html/wiki/lib/plugins/combo/ComboStrap/TemplateForWebPage.php(162): ComboStrap\TemplateForWebPage->getModel()

7 /home/hasmotinc/public_html/wiki/lib/plugins/combo/ComboStrap/FetcherPage.php(154): ComboStrap\TemplateForWebPage->render()

8 /home/hasmotinc/public_html/wiki/lib/plugins/combo/action/docustom.php(180): ComboStrap\FetcherPage->getFetchString()

9 /home/hasmotinc/public_html/wiki/inc/Extension/EventHandler.php(80): action_plugin_combo_docustom->executeComboDoAction(Object(dokuwiki\Extension\Event), NULL)

10 /home/hasmotinc/public_html/wiki/inc/Extension/Event.php(75): dokuwiki\Extension\EventHandler->process_event(Object(dokuwiki\Extension\Event), 'BEFORE')

11 /home/hasmotinc/public_html/wiki/inc/ActionRouter.php(83): dokuwiki\Extension\Event->advise_before()

12 /home/hasmotinc/public_html/wiki/inc/ActionRouter.php(49): dokuwiki\ActionRouter->setupAction('show')

13 /home/hasmotinc/public_html/wiki/inc/ActionRouter.php(62): dokuwiki\ActionRouter->__construct()

14 /home/hasmotinc/public_html/wiki/inc/actions.php(19): dokuwiki\ActionRouter::getInstance(true)

15 /home/hasmotinc/public_html/wiki/doku.php(131): act_dispatch()

16 {main}

EVENTUALLY LEADING TO:

0 /home/hasmotinc/public_html/wiki/inc/parserutils.php(299): p_render_metadata('visual3d:tutori...', Array)

1 /home/hasmotinc/public_html/wiki/inc/common.php(262): p_get_metadata('visual3d:tutori...')

2 /home/hasmotinc/public_html/wiki/doku.php(101): pageinfo()

3 {main}

Cheers!

gerardnico commented 1 month ago

It depends on the page content.

To reduce the size and increase performance, we capture any xml/html node.

This kind of message can be seen when a html node is present but not escaped with 2 percentage characters.

Ie

%%<whateverer>%%
<!--And-->
%%</whateverer>%%

Otherwise I need the page content to check further the parsing.

Greetings !

GitHub don't let me put code ... I'll format that later.

gerardnico commented 1 month ago

list_open is a tag of dokuwiki that is created by the list * character. This kind of message are parsing message.

Here a test page with a second and third heading: https://demo.combostrap.com/one-second-header-test And it works.

gerardnico commented 1 month ago

I deleted the php8 array warning EditButton.php(269) E_WARNING Next release, you will not see it.

gerardnico commented 1 month ago

For the error:

PDO->exec('ALTER TABLE ali...')

Combostrap does not have any table or migration script starting with ali in its database

It seems to come from the action_plugin_data