All add-ons currently require PHP 7.4 or greater.

On July 4th 2024 PHP 8.2 will be the new minimum requirement for all add-ons. Expect any add-on released after that date to require 8.2 or greater. Some releases may not immediately take advantage of 8.x specific features in PHP, which means you might, be able to continue using new releases in PHP 7.4, however, if you experience an error the first thing you should do is update to PHP 8.2 then create a support ticket if the error persists.

Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: Critical bug when editing pages or refreshing cached ones

Status Resolved
Add-on / Version Publisher 3.10.0 and 3.11.0
Severity
EE Version 7.3.14 and 7.3.15

Juan Carlos Celaya Dibout

Jan 19, 2024

I had to restore a backup from previous day because the error seems to affect page generation too and after cleaning cache i got errors on all pages related to wrong api key, so site was essentially nuked except home page, all pages were giving blank pages with EE errors to the public. Restored backup is EE 7.3.14 and Publisher 3.10.0, now i get this error when trying to edit any page. I can’t recreate the error with EE 7.3.15 and Publisher 3.11.0 but it happened doing the same.

I can’t update deepl api key, i get this error “Fieldtypes: The option you selected is not valid.” no matter if i select none, one or the fields that were there before.

BoldMinded\Publisher\Dependency\DeepL\AuthorizationException Caught
Authorization failure, check authentication key
user/addons/publisher/vendor-build/deeplcom/deepl-php/src/Translator.php:509

Stack Trace: Please include when reporting this error
#0 user/addons/publisher/vendor-build/deeplcom/deepl-php/src/Translator.php(57): BoldMinded\Publisher\Dependency\DeepL\Translator->checkStatusCode(Array)
#1 user/addons/publisher/Service/Translators/Deepl.php(156): BoldMinded\Publisher\Dependency\DeepL\Translator->getUsage()
#2 user/addons/publisher/Service/Toolbar.php(371): BoldMinded\Publisher\Service\Translators\Deepl->isApiUsageReached()
#3 user/addons/publisher/tab.publisher.php(92): BoldMinded\Publisher\Service\Toolbar->compileOptions()
#4 ee/ExpressionEngine/Model/Channel/ChannelEntry.php(884): Publisher_tab->display(4, 628)
#5 ee/ExpressionEngine/Model/Channel/ChannelEntry.php(1256): ExpressionEngine\Model\Channel\ChannelEntry->getTabFields()
#6 ee/ExpressionEngine/Model/Content/ContentModel.php(354): ExpressionEngine\Model\Channel\ChannelEntry->getDefaultFields()
#7 ee/ExpressionEngine/Model/Content/ContentModel.php(302): ExpressionEngine\Model\Content\ContentModel->initializeCustomFields()
#8 ee/ExpressionEngine/Model/Content/ContentModel.php(186): ExpressionEngine\Model\Content\ContentModel->usesCustomFields()
#9 ee/ExpressionEngine/Addons/pro/Model/Channel/ChannelEntry.php(33): ExpressionEngine\Model\Content\ContentModel->set(Array)
#10 ee/ExpressionEngine/Controller/Publish/Edit.php(401): ExpressionEngine\Addons\Pro\Model\Channel\ChannelEntry->set(Array)
#11 [internal function]: ExpressionEngine\Controller\Publish\Edit->entry(‘628’)
#12 ee/ExpressionEngine/Core/Core.php(268): call_user_func_array(Array, Array)
#13 ee/ExpressionEngine/Core/Core.php(124): ExpressionEngine\Core\Core->runController(Array)
#14 ee/ExpressionEngine/Boot/boot.php(184): ExpressionEngine\Core\Core->run(Object(ExpressionEngine\Core\Request))
#15 public_html/contenidos.php(144): require_once(’...’)
#15 public_html/contenidos.php(144): require_once(’...’)

#1

BoldMinded (Brian)

You’re trying to update an api key, but you get the field type error? Does the CP page load at all? Can you share a video of what you’re trying to do b/c this isn’t something I can replicate right now.

#2

BoldMinded (Brian)

Is this happening on the front-end, or in the CP? I’m taking a total guess here but update the isApiUsageReached method in the Services/Translators/Deepl.php file to this:

public function isApiUsageReached(): bool
    {
        try {
            return $this->translator->getUsage()->anyLimitReached();
        } catch (DeepLException $exception) {
            if (REQ === 'CP') {
                (new TranslatorErrorHandler($this->getName()))->handle($exception->getMessage());
            }
        }
        
        return false;
    }
#3

Juan Carlos Celaya Dibout

Thanks, your code modification solved the editor issue, i don’t feel like emptying the cache on a Friday afternoon tho as i would have to restore cache folder from backup if it didn’t work and it’s a bit cumbersome, i will test the public part on Monday.

I still can’t change the api key or any autotranslation settings, video here: https://1drv.ms/v/s!AqP_yNWIPyhykiFHCEDm_a0V4X8b?e=PBcEOQ

Regards,

#4

BoldMinded (Brian)

Good to hear that code change fixed one issue. The 1drv link you sent though isn’t displaying anything.

#5

Juan Carlos Celaya Dibout

Comment has been marked private.

#6

Juan Carlos Celaya Dibout

Comment has been marked private.

#7

BoldMinded (Brian)

Neither of those are loading for me :( Are you able to share on Dropbox or something?

#8

Juan Carlos Celaya Dibout

Comment has been marked private.

#9

BoldMinded (Brian)

So that error message is coming from EE, not Publisher, and I’m not able to replicate it. I can save that settings form in various states and it saves correctly each time, The differentiator is that it looks like you have Freeform installed, and I don’t have that. Have you tried backing up your db, uninstalling Freeform, and then see if that Auto Translations settings pages saves correctly?

#10

Juan Carlos Celaya Dibout

Comment has been marked private.

#11

BoldMinded (Brian)

You can’t make local backup of a database, uninstall, test locally, and then restore the database?

The deepl key is stored in the publisher settings table.

#12

Juan Carlos Celaya Dibout

Comment has been marked private.

Login to reply