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: Publisher is blocking upgrade from ExpressionEngine 3.5.16 to 4.3.1 because of fatal error

Status Resolved
Add-on / Version Publisher 2.8.2
Severity
EE Version 3.5.16

Burgi von Mengershausen

Jun 20, 2018

Description:
I’m trying to upgrade from ExpressionEngine 3.5.16 to 4.3.1
and i’m getting the following fatal error within the ExpressionEngine updater:

Fatal error: Uncaught Error: Call to a member function setCurrentStatus() on null in /kunden/tannerhof.de/ee4/eeengine/user/addons/publisher/ext.publisher.php:199 Stack trace: #0 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Extensions.php(221): Publisher_ext->sessions_start(Object(EE_Session)) #1 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Extensions.php(116): EE_Extensions->call_class('Publisher_ext', 'sessions_start', Array, Array) #2 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Session.php(121): EE_Extensions->call('sessions_start', Object(EE_Session)) #3 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/core/Loader.php(1034): EE_Session->__construct(Array) #4 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/core/Loader.php(949): EE_Loader->_ci_init_class('session', '', Array, NULL) #5 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/core/Loader.php(171): EE_Loader->_ci_load_class('Session', NULL, NULL) #6 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Core.php(293): EE_Loader->library('session') #7 in /kunden/tannerhof.de/ee4/eeengine/user/addons/publisher/ext.publisher.php on line 199


Detailed steps to reproduce the issue:
1. updated all addons to latest version
2. updated ExpressionEngine to version 3.5.16
3. run the updater from 3.5.16 to 4.3.1

 

#1

BoldMinded (Brian)

Try making this change… add the following to the ext file right before that error is thrown on line 199.

public function sessions_start()
    {
        if (session_id() === '' && REQ === 'CP') {
            @session_start();
        }

        // add this conditional
        if ($this->isUpdating()) {
            return;
        }
#2

BoldMinded (Brian)

Do you have custom member fields in your site?

#3

Burgi von Mengershausen

no custom member fields at all!

when i incorporate your code right before line 199 in ext.publisher.php

i get now

Parse error: syntax error, unexpected ‘public’ (T_PUBLIC) in /kunden/tannerhof.de/ee4/eeengine/user/addons/publisher/ext.publisher.php on line 199

#4

BoldMinded (Brian)

My code snippet was just the beginning of the function, don’t paste the whole thing in there, just add the “if ($this->isUpdating()) {” part.

#5

Burgi von Mengershausen

Did this now and now i get:

Fatal error: Uncaught Error: Call to a member function isCurrentStatusDraft() on null in /kunden/tannerhof.de/ee4/eeengine/user/addons/publisher/ext.publisher.php:257 Stack trace: #0 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Extensions.php(221): Publisher_ext->core_boot() #1 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Extensions.php(116): EE_Extensions->call_class('Publisher_ext', 'core_boot', Array, Array) #2 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/core/Controller.php(90): EE_Extensions->call('core_boot') #3 /kunden/tannerhof.de/ee4/eeengine/ee/EllisLab/ExpressionEngine/Core/Core.php(227): EE_Controller->__construct() #4 /kunden/tannerhof.de/ee4/eeengine/ee/EllisLab/ExpressionEngine/Core/Core.php(109): EllisLab\ExpressionEngine\Core\Core->runController(Array) #5 /kunden/tannerhof.de/ee4/eeengine/ee/EllisLab/ExpressionEngine/Boot/boot.php(146): EllisLab\ExpressionEngine\Core\Core->run(Object(EllisLab\ExpressionEngine\Core\Request)) #6 /kunden/tannerhof.de/ee4/index.php(172): require_once('/kunden in /kunden/tannerhof.de/ee4/eeengine/user/addons/publisher/ext.publisher.php on line 257
#6

BoldMinded (Brian)

Ok then, add it just after the core_boot() method too.

public function core_boot()
    {
        if ($this->isUpdating()) {
            return;
        }
#7

Burgi von Mengershausen

Then i get

Fatal error: Uncaught Error: Call to a member function get() on null in /kunden/tannerhof.de/ee4/eeengine/user/addons/publisher/ext.publisher.php:951 Stack trace: #0 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Extensions.php(221): Publisher_ext->core_template_route(”) #1 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Extensions.php(116): EE_Extensions->call_class(‘Publisher_ext’, ‘core_template_r…’, Array, Array) #2 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/libraries/Core.php(604): EE_Extensions->call(‘core_template_r…’, ”) #3 /kunden/tannerhof.de/ee4/eeengine/ee/legacy/controllers/ee.php(62): EE_Core->generate_page() #4 [internal function]: EE->index() #5 /kunden/tannerhof.de/ee4/eeengine/ee/EllisLab/ExpressionEngine/Core/Core.php(240): call_user_func_array(Array, Array) #6 /kunden/tannerhof.de/ee4/eeengine/ee/EllisLab/ExpressionEngine/Core/Core.php(109): EllisLab\ExpressionEngine\Core\Core->runController(Array) #7 /kunden/tannerhof.de/ee4/eeengine/ee/EllisLab/ExpressionEngine/Boot/boot.php(146): in /kunden/tannerhof.de/ee4/eeengine/user/addons/publisher/ext.publisher.php on line 951

#8

BoldMinded (Brian)

This shouldn’t be happening. Have you tried setting ‘allow_extensions’ = ‘n’ in your config file before running the upgrade? Then changing it back?

$config['allow_extensions'] = 'n';
#9

BoldMinded (Brian)

Did disabling extensions work? I thought that was a recommended path in the EE upgrade docs too.

#10

Burgi von Mengershausen

no it did not work but it might not be because of publisher … working on it … keep you posted, thanks

#11

Burgi von Mengershausen

When i disable extensions with $config[‘allow_extensions’] = ‘n’;

i now get this error:

Exception Caught
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'db42490_4.exp_channels_channel_field_groups' doesn't exist:
SELECT Channel_channels.channel_id as Channel__channel_id, Channel_channels.site_id as Channel__site_id, Channel_channels.channel_name as Channel__channel_name, Channel_channels.channel_title as Channel__channel_title, Channel_channels.channel_url as Channel__channel_url, Channel_channels.channel_description as Channel__channel_description, Channel_channels.channel_lang as Channel__channel_lang, Channel_channels.total_entries as Channel__total_entries, Channel_channels.total_records as Channel__total_records, Channel_channels.total_comments as Channel__total_comments, Channel_channels.last_entry_date as Channel__last_entry_date, Channel_channels.last_comment_date as Channel__last_comment_date, Channel_channels.cat_group as Channel__cat_group, Channel_channels.deft_status as Channel__deft_status, Channel_channels.search_excerpt as Channel__search_excerpt, Channel_channels.deft_category as Channel__deft_category, Channel_channels.deft_comments as Channel__deft_comments, Channel_channels.channel_require_membership as Channel__channel_require_membership, Channel_channels.channel_max_chars as Channel__channel_max_chars, Channel_channels.channel_html_formatting as Channel__channel_html_formatting, Channel_channels.extra_publish_controls as Channel__extra_publish_controls, Channel_channels.channel_allow_img_urls as Channel__channel_allow_img_urls, Channel_channels.channel_auto_link_urls as Channel__channel_auto_link_urls, Channel_channels.channel_notify as Channel__channel_notify, Channel_channels.channel_notify_emails as Channel__channel_notify_emails, Channel_channels.comment_url as Channel__comment_url, Channel_channels.comment_system_enabled as Channel__comment_system_enabled, Channel_channels.comment_require_membership as Channel__comment_require_membership, Channel_channels.comment_moderate as Channel__comment_moderate, Channel_channels.comment_max_chars as Channel__comment_max_chars, Channel_channels.comment_timelock as Channel__comment_timelock, Channel_channels.comment_require_email as Channel__comment_require_email, Channel_channels.comment_text_formatting as Channel__comment_text_formatting, Channel_channels.comment_html_formatting as Channel__comment_html_formatting, Channel_channels.comment_allow_img_urls as Channel__comment_allow_img_urls, Channel_channels.comment_auto_link_urls as Channel__comment_auto_link_urls, Channel_channels.comment_notify as Channel__comment_notify, Channel_channels.comment_notify_authors as Channel__comment_notify_authors, Channel_channels.comment_notify_emails as Channel__comment_notify_emails, Channel_channels.comment_expiration as Channel__comment_expiration, Channel_channels.search_results_url as Channel__search_results_url, Channel_channels.rss_url as Channel__rss_url, Channel_channels.enable_versioning as Channel__enable_versioning, Channel_channels.max_revisions as Channel__max_revisions, Channel_channels.default_entry_title as Channel__default_entry_title, Channel_channels.title_field_label as Channel__title_field_label, Channel_channels.url_title_prefix as Channel__url_title_prefix, Channel_channels.max_entries as Channel__max_entries, Channel_channels.preview_url as Channel__preview_url, FieldGroups_field_groups.group_id as FieldGroups__group_id, FieldGroups_field_groups.site_id as FieldGroups__site_id, FieldGroups_field_groups.group_name as FieldGroups__group_name, CustomFields_channel_fields.field_id as CustomFields__field_id, CustomFields_channel_fields.site_id as CustomFields__site_id, CustomFields_channel_fields.field_name as CustomFields__field_name, CustomFields_channel_fields.field_label as CustomFields__field_label, Channel_FieldGroups_channels_channel_field_groups ON `Channel_FieldGroups_channels_channel_field_groups`.`channel_id` = `Channel_channels`.`channel_id` LEFT JOIN `exp_field_groups` as FieldGroups_field_groups ON `FieldGroups_field_groups`.`group_id` = `Channel_FieldGroups_channels_channel_field_groups`.`group_id` LEFT JOIN `exp_channels_channel_fields` as Channel_CustomFields_channels_channel_fields ON `Channel_CustomFields_channels_channel_fields`.`channel_id` = `Channel_channels`.`channel_id` LEFT JOIN `exp_channel_fields` as CustomFields_channel_fields ON `CustomFields_channel_fields`.`field_id` = `Channel_CustomFields_channels_channel_fields`.`field_id` WHERE ( `Channel_channels`.`channel_id` IN (1) ) LIMIT 18446744073709551615
ee/legacy/database/drivers/mysqli/mysqli_connection.php:116
#12

Burgi von Mengershausen

but table “exp_channels_channel_field_groups” does not exist and has never existed … there is only “exp_field_groups” … very strange

#13

BoldMinded (Brian)

Did you start over from scratch after changing that config value or did you try to continue from where you left off? That error isn’t Publisher related, so I’m not sure what is happening.

#14

Burgi von Mengershausen

I did start over from scratch. Just opened a ticket at ExpressionEngine support.

#15

Burgi von Mengershausen

hi Brian,

It’s a bug on ExpressionEngines end … Robin worked it out. The problem only happens if you have these two config overrides set and then try to update to ee4:

$config[‘base_path’] = ‘value’; $config[‘base_url’] = ‘value’;

without them the update worked fine and publisher did not show up again.

Thanks Axel

#16

BoldMinded (Brian)

Sounds like an interesting bug. Glad it was found though. I’ll go ahead and close this ticket.

Login to reply