[3.3][RC] Autolinks 1.3.9

A place for Extension Authors to post and receive feedback on Extensions still in development. No Extensions within this forum should be used within a live environment!
Scam Warning
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: Extensions Development rules

IMPORTANT FOR NEEDED EVENTS!!!
If you need an event for your extension please read this for the steps to follow to request the event(s)
PoFi
Registered User
Posts: 7
Joined: Sun Feb 10, 2008 1:07 pm

Re: [3.3][RC] Autolinks 1.3.5

Post by PoFi »

Sometimes you just have a board in front of your head... :roll:
For anyone interested in a solution:

open ext/lmdi/autolinks/event/listener.php

search:

Code: Select all

$lastspace = ')\b/ui; // PCRE - u = UTF-8 - i = case insensitive
replace:

Code: Select all

$lastspace = ')\b/u; // PCRE - u = UTF-8 - i = case insensitive
Two lines would have to be changed.
I assume this will look similar in the glossary extension, but that's a different site.
Since I'm not that good with these extensions in phpbb, maybe that's a nice story for the next update. If desired, the user could choose in the ACP to be case sensitive or not.
For now, the solution presented above is satisfactory. Thanks for your Support :-)

Edit: Nice side effect; the extension thus also supports singular AND plural expressions. Previously, the presentation in the posts was sometimes incorrect.
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [3.3][RC] Autolinks 1.3.5

Post by romeo_piter »

Hello, Pierre.
The extention doesn't work for me. It crashes when I try to turn it on in the extention management of my admin panel. Got the following error:

Code: Select all

Общая ошибка
SQL ERROR [ mysqli ]
 
Table 'forum.phpbb_autolinks' doesn't exist [1146]
 
SQL
 
alter table phpbb_autolinks convert to character set utf8 collate utf8_unicode_ci
 
BACKTRACE
 
FILE: (not given by php)
LINE: (not given by php)
CALL: msg_handler()
 
FILE: [ROOT]/phpbb/db/driver/driver.php
LINE: 1023
CALL: trigger_error()
 
FILE: [ROOT]/phpbb/db/driver/mysqli.php
LINE: 202
CALL: phpbb\db\driver\driver->sql_error()
 
FILE: [ROOT]/phpbb/db/driver/factory.php
LINE: 345
CALL: phpbb\db\driver\mysqli->sql_query()
 
FILE: [ROOT]/ext/lmdi/autolinks/migrations/migration_2.php
LINE: 60
CALL: phpbb\db\driver\factory->sql_query()
 
FILE: (not given by php)
LINE: (not given by php)
CALL: lmdi\autolinks\migrations\migration_2->utf8_unicode_ci()
 
FILE: [ROOT]/phpbb/db/migrator.php
LINE: 715
CALL: call_user_func_array()
 
FILE: [ROOT]/phpbb/db/migrator.php
LINE: 662
CALL: phpbb\db\migrator->run_step()
 
FILE: [ROOT]/phpbb/db/migrator.php
LINE: 437
CALL: phpbb\db\migrator->process_data_step()
 
FILE: [ROOT]/phpbb/db/migrator.php
LINE: 352
CALL: phpbb\db\migrator->try_apply()
 
FILE: [ROOT]/phpbb/db/migrator.php
LINE: 352
CALL: phpbb\db\migrator->try_apply()
 
FILE: [ROOT]/phpbb/db/migrator.php
LINE: 288
CALL: phpbb\db\migrator->try_apply()
 
FILE: [ROOT]/phpbb/db/migrator.php
LINE: 241
CALL: phpbb\db\migrator->update_do()
 
FILE: [ROOT]/phpbb/extension/base.php
LINE: 78
CALL: phpbb\db\migrator->update()
 
FILE: [ROOT]/phpbb/extension/manager.php
LINE: 231
CALL: phpbb\extension\base->enable_step()
 
FILE: [ROOT]/ext/boardtools/upload/includes/functions/extensions.php
LINE: 294
CALL: phpbb\extension\manager->enable_step()
 
FILE: [ROOT]/ext/boardtools/upload/acp/upload_module.php
LINE: 181
CALL: boardtools\upload\includes\functions\extensions::enable()
 
FILE: [ROOT]/includes/functions_module.php
LINE: 676
CALL: boardtools\upload\acp\upload_module->main()
 
FILE: [ROOT]/adm/index.php
LINE: 81
CALL: p_master->load_active()
MySQL(i) 8.0.34-0ubuntu0.22.04.1
php 8.1.2-1ubuntu2.14
phpbb 3.3.10

No errors in my server logs. What can I do about it?
User avatar
pierredu
Registered User
Posts: 1274
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [3.3][RC] Autolinks 1.3.5

Post by pierredu »

That means that the table was not created in the installation process.
Redo the installation.
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [3.3][RC] Autolinks 1.3.5

Post by romeo_piter »

I can't redo because I can't delete the data of the extention. There's an error when trying to delete it in the admin panel:

Code: Select all

SQL ERROR [ mysqli ]

Table 'forum.phpbb_autolinks' doesn't exist [1146]

SQL

SELECT COUNT(*) as nb FROM phpbb_autolinks WHERE 1

BACKTRACE

FILE: (not given by php)
LINE: (not given by php)
CALL: msg_handler()

FILE: [ROOT]/phpbb/db/driver/driver.php
LINE: 1023
CALL: trigger_error()

FILE: [ROOT]/phpbb/db/driver/mysqli.php
LINE: 202
CALL: phpbb\db\driver\driver->sql_error()

FILE: [ROOT]/phpbb/db/driver/factory.php
LINE: 345
CALL: phpbb\db\driver\mysqli->sql_query()

FILE: [ROOT]/ext/lmdi/autolinks/migrations/migration_1.php
LINE: 48
CALL: phpbb\db\driver\factory->sql_query()

FILE: [ROOT]/ext/lmdi/autolinks/migrations/migration_1.php
LINE: 75
CALL: lmdi\autolinks\migrations\migration_1->get_nbrows()

FILE: [ROOT]/phpbb/db/migrator.php
LINE: 589
CALL: lmdi\autolinks\migrations\migration_1->revert_schema()

FILE: [ROOT]/phpbb/db/migrator.php
LINE: 518
CALL: phpbb\db\migrator->try_revert()

FILE: [ROOT]/phpbb/db/migrator.php
LINE: 489
CALL: phpbb\db\migrator->revert_do()

FILE: [ROOT]/phpbb/extension/base.php
LINE: 108
CALL: phpbb\db\migrator->revert()

FILE: [ROOT]/phpbb/extension/manager.php
LINE: 341
CALL: phpbb\extension\base->purge_step()

FILE: [ROOT]/includes/acp/acp_extensions.php
LINE: 305
CALL: phpbb\extension\manager->purge_step()

FILE: [ROOT]/includes/functions_module.php
LINE: 676
CALL: acp_extensions->main()

FILE: [ROOT]/adm/index.php
LINE: 81
CALL: p_master->load_active()
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [3.3][RC] Autolinks 1.3.5

Post by romeo_piter »

Ok. I've solved the first problem by using STK and installed the ext. Now I have another problem. The words transform into links, but the links are not clickable. Plain text. (((
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [3.3][RC] Autolinks 1.3.5

Post by romeo_piter »

It works only with terms in English, doesn't work with Russian. Any solutions?
User avatar
pierredu
Registered User
Posts: 1274
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [3.3][RC] Autolinks 1.3.5

Post by pierredu »

It does work with terms in cyrillic. I just tested.
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [3.3][RC] Autolinks 1.3.5

Post by romeo_piter »

Got this in my server logs:

Code: Select all

[Wed Sep 27 07:44:06.334930 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: PHP Fatal error:  Uncaught InvalidArgumentException: Invalid UTF-8 input in /var/www/xxxxx/data/www/xxxxx.ru/vendor/s9e/text-formatter/src/Parser.php:216, referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335211 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: Stack trace:, referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335222 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #0 /var/www/xxxxx/data/www/xxxxx.ru/vendor/s9e/text-formatter/src/Parser.php(340): s9e\\TextFormatter\\Parser->reset('\\xD0\\x9D\\xD0\\xB0\\xD0\\xB1\\xD0\\xB8\\xD0\\xBB\\xD0\\xB8 \\xD0\\xBE...'), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335231 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #1 /var/www/xxxxx/data/www/xxxxx.ru/phpbb/textformatter/s9e/parser.php(91): s9e\\TextFormatter\\Parser->parse('\\xD0\\x9D\\xD0\\xB0\\xD0\\xB1\\xD0\\xB8\\xD0\\xBB\\xD0\\xB8 \\xD0\\xBE...'), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335239 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #2 /var/www/xxxxx/data/www/xxxxx.ru/includes/message_parser.php(1250): phpbb\\textformatter\\s9e\\parser->parse('\\xD0\\x9D\\xD0\\xB0\\xD0\\xB1\\xD0\\xB8\\xD0\\xBB\\xD0\\xB8 \\xD0\\xBE...'), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335247 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #3 /var/www/xxxxx/data/www/xxxxx.ru/includes/functions_content.php(724): parse_message->parse('1', '1', '1', false, false, false, true, true, 'text_reparser.p...'), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335255 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #4 /var/www/xxxxx/data/www/xxxxx.ru/phpbb/textreparser/base.php(259): generate_text_for_storage('\\xD0\\x9D\\xD0\\xB0\\xD0\\xB1\\xD0\\xB8\\xD0\\xBB\\xD0\\xB8 \\xD0\\xBE...', '', '', 7, '1', '1', '1', false, false, false, true, 'text_reparser.p...'), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335264 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #5 /var/www/xxxxx/data/www/xxxxx.ru/phpbb/textreparser/base.php(223): phpbb\\textreparser\\base->reparse_record(Array), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335272 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #6 /var/www/xxxxx/data/www/xxxxx.ru/phpbb/cron/task/text_reparser/reparser.php(159): phpbb\\textreparser\\base->reparse_range(408211, 408310), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335280 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #7 [internal function]: phpbb\\cron\\task\\text_reparser\\reparser->run(), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335287 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #8 /var/www/xxxxx/data/www/xxxxx.ru/phpbb/cron/task/wrapper.php(139): call_user_func_array(Array, Array), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335294 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #9 /var/www/xxxxx/data/www/xxxxx.ru/phpbb/cron/event/cron_runner_listener.php(86): phpbb\\cron\\task\\wrapper->__call('run', Array), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335302 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #10 /var/www/xxxxx/data/www/xxxxx.ru/vendor/symfony/event-dispatcher/EventDispatcher.php(214): phpbb\\cron\\event\\cron_runner_listener->on_kernel_terminate(Object(Symfony\\Component\\HttpKernel\\Event\\PostResponseEvent), 'kernel.terminat...', Object(phpbb\\event\\dispatcher)), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335322 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #11 /var/www/xxxxx/data/www/xxxxx.ru/vendor/symfony/event-dispatcher/EventDispatcher.php(44): Symfony\\Component\\EventDispatcher\\EventDispatcher->doDispatch(Array, 'kernel.terminat...', Object(Symfony\\Component\\HttpKernel\\Event\\PostResponseEvent)), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335332 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #12 /var/www/xxxxx/data/www/xxxxx.ru/phpbb/event/dispatcher.php(62): Symfony\\Component\\EventDispatcher\\EventDispatcher->dispatch('kernel.terminat...', Object(Symfony\\Component\\HttpKernel\\Event\\PostResponseEvent)), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335341 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #13 /var/www/xxxxx/data/www/xxxxx.ru/vendor/symfony/http-kernel/HttpKernel.php(88): phpbb\\event\\dispatcher->dispatch('kernel.terminat...', Object(Symfony\\Component\\HttpKernel\\Event\\PostResponseEvent)), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335349 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #14 /var/www/xxxxx/data/www/xxxxx.ru/app.php(37): Symfony\\Component\\HttpKernel\\HttpKernel->terminate(Object(phpbb\\symfony_request), Object(Symfony\\Component\\HttpFoundation\\Response)), referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335356 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr: #15 {main}, referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:44:06.335360 2023] [fcgid:warn] [pid 1127863] [client 95.105.66.193:57084] mod_fcgid: stderr:   thrown in /var/www/xxxxx/data/www/xxxxx.ru/vendor/s9e/text-formatter/src/Parser.php on line 216, referer: https://xxxxx.ru/viewtopic.php?t=17788
[Wed Sep 27 07:51:35.831134 2023] [fcgid:warn] [pid 1128536] (32)Broken pipe: [client 109.238.247.83:32980] mod_fcgid: ap_pass_brigade failed in handle_request_ipc function
[Wed Sep 27 07:51:43.771348 2023] [fcgid:warn] [pid 1128543] (32)Broken pipe: [client 109.238.247.83:45684] mod_fcgid: ap_pass_brigade failed in handle_request_ipc function
[Wed Sep 27 07:51:53.544161 2023] [fcgid:warn] [pid 1128565] (32)Broken pipe: [client 109.238.247.83:39588] mod_fcgid: ap_pass_brigade failed in handle_request_ipc function
User avatar
pierredu
Registered User
Posts: 1274
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [3.3][RC] Autolinks 1.3.5

Post by pierredu »

Could you check the collation setting for the two text columns of the table phpbb(3)_autolinks ?
In the normal installation, you should have utf8_unicode_ci.
On my test server, it works also with utf8mb3_unicode_ci.
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [3.3][RC] Autolinks 1.3.5

Post by romeo_piter »

both utf8mb3_bin
User avatar
pierredu
Registered User
Posts: 1274
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [3.3][RC] Autolinks 1.3.5

Post by pierredu »

The migrations file should set it to utf8_unicode_ci. Try to modify it manually.
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [3.3][RC] Autolinks 1.3.5

Post by romeo_piter »

Hello. Got this mistake in only one topic:

Code: Select all

phpBB Debug] PHP Warning: in file [ROOT]/ext/lmdi/autolinks/event/listener.php on line 237: Undefined array key 33
[phpBB Debug] PHP Warning: in file [ROOT]/ext/lmdi/autolinks/event/listener.php on line 237: Trying to access array offset on value of type null
User avatar
pierredu
Registered User
Posts: 1274
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [3.3][RC] Autolinks 1.3.5

Post by pierredu »

Hello,

Is there something special with this topic?
Does the extension work fin in other topics?
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [3.3][RC] Autolinks 1.3.5

Post by romeo_piter »

For now I can see it only in one post.
Nothing special. But the topic with the problem was created by moving several posts from another topic by phpbb standard means.
User avatar
pierredu
Registered User
Posts: 1274
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [3.3][RC] Autolinks 1.3.5

Post by pierredu »

Give me a link to this topic.

Return to “Extensions in Development”