Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot upgrade from 3.3.15 to 3.3.16.* #5284

Closed
ccchapman opened this issue Nov 28, 2019 · 9 comments
Closed

Cannot upgrade from 3.3.15 to 3.3.16.* #5284

ccchapman opened this issue Nov 28, 2019 · 9 comments

Comments

@ccchapman
Copy link

@ccchapman ccchapman commented Nov 28, 2019

Description

I am unable to update Craft CMS from 3.3.15 to 3.3.16.*.

I receive various errors about a compiled class. When I review the file, nothing looks out of place. I notice that the syntax errors are all tripped inside PHP comments. (Like // ===... or /* */)

Steps to reproduce

  1. Update craftcms/cms requirement to ^3.3, 3.3.16.1, etc.
  2. composer update
  3. Visit CP
  4. Receive an error about unexpected contents in ./storage/runtime/compiled_classes/ContentBehavior.php
  5. Delete ./storage/runtime
  6. Reload CP, it works
  7. Reload CP, error occurs again
2019-11-28 17:08:27 [-][-][error][ParseError] ParseError: syntax error, unexpected '*', expecting function (T_FUNCTION) or const (T_CONST) in /home/vagrant/site/storage/runtime/compiled_classes/ContentBehavior.php:602
Stack trace:
#0 /home/vagrant/site/vendor/craftcms/cms/src/Craft.php(186): Craft::_loadFieldAttributesFile('/home/vagrant/h...', 'ZOh3GsHbAJTV')
#1 [internal function]: Craft::autoload('craft\\behaviors...')
#2 [internal function]: spl_autoload_call('craft\\behaviors...')
#3 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(431): ReflectionClass->__construct('craft\\behaviors...')
#4 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(365): yii\di\Container->getDependencies('craft\\behaviors...')
#5 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(156): yii\di\Container->build('craft\\behaviors...', Array, Array)
#6 /home/vagrant/site/vendor/yiisoft/yii2/BaseYii.php(345): yii\di\Container->get('craft\\behaviors...', Array)
#7 /home/vagrant/site/vendor/yiisoft/yii2/base/Component.php(750): yii\BaseYii::createObject('craft\\behaviors...')
#8 /home/vagrant/site/vendor/yiisoft/yii2/base/Component.php(734): yii\base\Component->attachBehaviorInternal('customFields', 'craft\\behaviors...')
#9 /home/vagrant/site/vendor/yiisoft/yii2/base/Component.php(465): yii\base\Component->ensureBehaviors()
#10 /home/vagrant/site/vendor/craftcms/cms/src/db/Query.php(54): yii\base\Component->hasEventHandlers('init')
#11 /home/vagrant/site/vendor/yiisoft/yii2/base/BaseObject.php(109): craft\db\Query->init()
#12 /home/vagrant/site/vendor/craftcms/cms/src/elements/db/ElementQuery.php(488): yii\base\BaseObject->__construct(Array)
#13 /home/vagrant/site/vendor/craftcms/cms/src/elements/GlobalSet.php(87): craft\elements\db\ElementQuery->__construct('craft\\elements\\...')
#14 /home/vagrant/site/vendor/craftcms/cms/src/base/Element.php(2374): craft\elements\GlobalSet::find()
#15 /home/vagrant/site/vendor/craftcms/cms/src/base/Element.php(407): craft\base\Element::findByCondition(NULL, false)
#16 /home/vagrant/site/vendor/craftcms/cms/src/services/Globals.php(155): craft\base\Element::findAll()
#17 /home/vagrant/site/vendor/craftcms/cms/src/services/Globals.php(294): craft\services\Globals->getAllSets()
#18 /home/vagrant/site/config/element-api.php(8): craft\services\Globals->getSetByHandle('globalLinks')
#19 /home/vagrant/site/vendor/craftcms/cms/src/services/Config.php(211): include('/home/vagrant/h...')
#20 /home/vagrant/site/vendor/craftcms/cms/src/services/Plugins.php(887): craft\services\Config->getConfigFromFile('element-api')
#21 /home/vagrant/site/vendor/craftcms/cms/src/services/Plugins.php(230): craft\services\Plugins->createPlugin('element-api', Array)
#22 /home/vagrant/site/vendor/craftcms/cms/src/base/ApplicationTrait.php(1361): craft\services\Plugins->loadPlugins()
#23 /home/vagrant/site/vendor/craftcms/cms/src/web/Application.php(112): craft\web\Application->_postInit()
#24 /home/vagrant/site/vendor/yiisoft/yii2/base/BaseObject.php(109): craft\web\Application->init()
#25 /home/vagrant/site/vendor/yiisoft/yii2/base/Application.php(206): yii\base\BaseObject->__construct(Array)
#26 /home/vagrant/site/vendor/craftcms/cms/src/web/Application.php(100): yii\base\Application->__construct(Array)
#27 [internal function]: craft\web\Application->__construct(Array)
#28 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(384): ReflectionClass->newInstanceArgs(Array)
#29 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(156): yii\di\Container->build('craft\\web\\Appli...', Array, Array)
#30 /home/vagrant/site/vendor/yiisoft/yii2/BaseYii.php(349): yii\di\Container->get('craft\\web\\Appli...', Array, Array)
#31 /home/vagrant/site/vendor/craftcms/cms/bootstrap/bootstrap.php(244): yii\BaseYii::createObject(Array)
#32 /home/vagrant/site/vendor/craftcms/cms/bootstrap/web.php(52): require('/home/vagrant/h...')
#33 /home/vagrant/site/web/index.php(20): require('/home/vagrant/h...')
#34 {main}

Here is another variation of the error. It references Spoon, but I can delete that plugin and still have the issue.

2019-11-28 16:51:27 [-][-][error][ParseError] ParseError: syntax error, unexpected '===' (T_IS_IDENTICAL), expecting end of file in /home/vagrant/site/storage/runtime/compiled_classes/ContentBehavior.php:611
Stack trace:
#0 /home/vagrant/site/vendor/craftcms/cms/src/Craft.php(186): Craft::_loadFieldAttributesFile('/home/vagrant/h...', 'ZOh3GsHbAJTV')
#1 [internal function]: Craft::autoload('craft\\behaviors...')
#2 [internal function]: spl_autoload_call('craft\\behaviors...')
#3 /home/vagrant/site/vendor/craftcms/cms/src/services/Fields.php(1427): class_exists('craft\\behaviors...')
#4 /home/vagrant/site/vendor/craftcms/cms/src/services/Fields.php(984): craft\services\Fields->updateFieldVersion()
#5 /home/vagrant/site/vendor/angellco/spoon/src/services/BlockTypes.php(59): craft\services\Fields->refreshFields()
#6 [internal function]: angellco\spoon\services\BlockTypes->__construct(Array)
#7 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(392): ReflectionClass->newInstanceArgs(Array)
#8 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(159): yii\di\Container->build('angellco\\spoon\\...', Array, Array)
#9 /home/vagrant/site/vendor/yiisoft/yii2/BaseYii.php(345): yii\di\Container->get('angellco\\spoon\\...', Array)
#10 /home/vagrant/site/vendor/yiisoft/yii2/di/ServiceLocator.php(137): yii\BaseYii::createObject('angellco\\spoon\\...')
#11 /home/vagrant/site/vendor/yiisoft/yii2/base/Module.php(745): yii\di\ServiceLocator->get('blockTypes', false)
#12 /home/vagrant/site/vendor/yiisoft/yii2/di/ServiceLocator.php(74): yii\base\Module->get('blockTypes')
#13 /home/vagrant/site/vendor/angellco/spoon/src/Spoon.php(103): yii\di\ServiceLocator->__get('blockTypes')
#14 /home/vagrant/site/vendor/yiisoft/yii2/base/BaseObject.php(109): angellco\spoon\Spoon->init()
#15 /home/vagrant/site/vendor/yiisoft/yii2/base/Module.php(158): yii\base\BaseObject->__construct(Array)
#16 /home/vagrant/site/vendor/craftcms/cms/src/base/Plugin.php(130): yii\base\Module->__construct('spoon', Object(craft\web\Application), Array)
#17 [internal function]: craft\base\Plugin->__construct('spoon', Object(craft\web\Application), Array)
#18 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(400): ReflectionClass->newInstanceArgs(Array)
#19 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(159): yii\di\Container->build('angellco\\spoon\\...', Array, Array)
#20 /home/vagrant/site/vendor/yiisoft/yii2/BaseYii.php(351): yii\di\Container->get('angellco\\spoon\\...', Array, Array)
#21 /home/vagrant/site/vendor/craftcms/cms/src/services/Plugins.php(897): yii\BaseYii::createObject(Array, Array)
#22 /home/vagrant/site/vendor/craftcms/cms/src/services/Plugins.php(230): craft\services\Plugins->createPlugin('spoon', Array)
#23 /home/vagrant/site/vendor/craftcms/cms/src/base/ApplicationTrait.php(1375): craft\services\Plugins->loadPlugins()
#24 /home/vagrant/site/vendor/craftcms/cms/src/web/Application.php(112): craft\web\Application->_postInit()
#25 /home/vagrant/site/vendor/yiisoft/yii2/base/BaseObject.php(109): craft\web\Application->init()
#26 /home/vagrant/site/vendor/yiisoft/yii2/base/Application.php(206): yii\base\BaseObject->__construct(Array)
#27 /home/vagrant/site/vendor/craftcms/cms/src/web/Application.php(100): yii\base\Application->__construct(Array)
#28 [internal function]: craft\web\Application->__construct(Array)
#29 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(400): ReflectionClass->newInstanceArgs(Array)
#30 /home/vagrant/site/vendor/yiisoft/yii2/di/Container.php(159): yii\di\Container->build('craft\\web\\Appli...', Array, Array)
#31 /home/vagrant/site/vendor/yiisoft/yii2/BaseYii.php(351): yii\di\Container->get('craft\\web\\Appli...', Array, Array)
#32 /home/vagrant/site/vendor/craftcms/cms/bootstrap/bootstrap.php(244): yii\BaseYii::createObject(Array)
#33 /home/vagrant/site/vendor/craftcms/cms/bootstrap/web.php(52): require('/home/vagrant/h...')
#34 /home/vagrant/site/web/index.php(20): require('/home/vagrant/h...')
#35 {main}

Additional info

  • Craft version: 3.3.15
  • PHP version: 7.2.22
  • Database driver & version: MySQL 5.7.27
  • Plugins & versions:
barrelstrength/sprout-fields      3.4.4    International, Craft-friendly field types.
carlcs/craft-diywidget            2.0.1    Do It Yourself widget for Craft CMS
clubstudioltd/craft-asset-rev     6.0.2    A plugin to aid cache-busting in Craft 3
craftcms/aws-s3                   1.2.5    Amazon S3 integration for Craft CMS
craftcms/cms                      3.3.15   Craft CMS
craftcms/element-api              2.6.0    Create a JSON API for your elements in Craft
craftcms/redactor                 2.4.0    Edit rich text content in Craft CMS using Redactor by Imperavi.
cweagans/composer-patches         1.6.7    Provides a way to patch Composer packages.
doublesecretagency/craft-smartmap 3.2.2.1  The most comprehensive proximity search and mapping tool for Craft.
kint-php/kint                     2.2      Kint - debugging tool for PHP developers
laravel/homestead                 v7.20.0  A virtual machine for web artisans.
lukeyouell/craft-countryselect    1.1.2    Country select field type.
lukeyouell/craft-sentry           1.5.1    Error tracking that helps developers monitor and fix crashes in real time. Iterate continuously. Boost efficiency. Improve user experience.
mikestecker/craft-videoembedder   1.1.4    Craft plugin to generate an embed URL from a YouTube or Vimeo URL.
mmikkel/cp-clearcache             1.0.5    Less clickin’ to get clearin’
mmikkel/cp-field-inspect          1.0.7    Inspect field handles and easily edit field settings
nystudio107/craft-retour          3.1.29   Retour allows you to intelligently redirect legacy URLs, so that you don't lose SEO value when rebuilding & restructuring a website
nystudio107/craft-seomatic        3.2.35   SEOmatic facilitates modern SEO best practices & implementation for Craft CMS 3. It is a turnkey SEO system that is comprehensive, powerful, and flexible.
nystudio107/craft-similar         1.0.6    Similar for Craft lets you find elements, Entries, Categories, Commerce Products, etc, that are similar, based on... other related elements.
rias/craft-position-fieldtype     1.0.14   Brings back the Position fieldtype from Craft 2
sebastianlenz/linkfield           1.0.19   A Craft field type for selecting links
solspace/craft-freeform           3.5.4    The most reliable, intuitive and powerful form builder for Craft.
spicyweb/craft-neo                2.5.8    A Matrix-like field type that uses existing fields
supercool/buttonbox               2.0.4    A collection of utility field types for Craft
topshelfcraft/environment-label   3.1.5    ...so you don't forget where you are.
topshelfcraft/supersort           3.0.1    ...a super-duper sorting function for your Craft templates.
verbb/feed-me                     4.1.0    Import content from XML, RSS, CSV or JSON feeds into entries, categories, Craft Commerce products, and more.
verbb/navigation                  1.1.14.1 A Craft CMS plugin to create navigation menus for your site.
verbb/super-table                 2.3.1    Super-charge your Craft workflow with Super Table. Use it to group fields together or build complex Matrix-in-Matrix solutions.
vlucas/phpdotenv                  v2.6.1   Loads environment variables from `.env` to `getenv()`, `$_ENV` and `$_SERVER` automagically.

Potentially Related

#3475, 359b7f6

@ccchapman ccchapman changed the title Cannot upgrade from 3.3.15 to 3.3.16 Cannot upgrade from 3.3.15 to 3.3.16.* Nov 28, 2019
@tomasbreffitt

This comment has been minimized.

Copy link

@tomasbreffitt tomasbreffitt commented Nov 29, 2019

I am having a similar error after getting to 3.3.16.3. This is the error I'm getting:

ParseError: syntax error, unexpected 'or' (T_LOGICAL_OR), expecting end of file in /home/vagrant/eedc-exploreedmonton/storage/runtime/compiled_classes/ContentBehavior.php:1229
Stack trace:
#0 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/Craft.php(286): Craft::_writeFieldAttributesFile('/home/vagrant/e...', Array, Array, '/home/vagrant/e...', true)
#1 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/Craft.php(217): Craft::_generateContentBehaviorFile(Array, '/home/vagrant/e...', 'VDBh08h2hbGk', true)
#2 [internal function]: Craft::autoload('craft\\behaviors...')
#3 [internal function]: spl_autoload_call('craft\\behaviors...')
#4 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/services/Fields.php(1427): class_exists('craft\\behaviors...')
#5 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/services/Fields.php(984): craft\services\Fields->updateFieldVersion()
#6 /home/vagrant/eedc-exploreedmonton/vendor/angellco/spoon/src/services/BlockTypes.php(59): craft\services\Fields->refreshFields()
#7 [internal function]: angellco\spoon\services\BlockTypes->__construct(Array)
#8 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/di/Container.php(392): ReflectionClass->newInstanceArgs(Array)
#9 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/di/Container.php(159): yii\di\Container->build('angellco\\spoon\\...', Array, Array)
#10 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/BaseYii.php(345): yii\di\Container->get('angellco\\spoon\\...', Array)
#11 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/di/ServiceLocator.php(137): yii\BaseYii::createObject('angellco\\spoon\\...')
#12 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/base/Module.php(745): yii\di\ServiceLocator->get('blockTypes', false)
#13 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/di/ServiceLocator.php(74): yii\base\Module->get('blockTypes')
#14 /home/vagrant/eedc-exploreedmonton/vendor/angellco/spoon/src/Spoon.php(103): yii\di\ServiceLocator->__get('blockTypes')
#15 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/base/BaseObject.php(109): angellco\spoon\Spoon->init()
#16 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/base/Module.php(158): yii\base\BaseObject->__construct(Array)
#17 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/base/Plugin.php(130): yii\base\Module->__construct('spoon', Object(craft\web\Application), Array)
#18 [internal function]: craft\base\Plugin->__construct('spoon', Object(craft\web\Application), Array)
#19 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/di/Container.php(400): ReflectionClass->newInstanceArgs(Array)
#20 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/di/Container.php(159): yii\di\Container->build('angellco\\spoon\\...', Array, Array)
#21 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/BaseYii.php(351): yii\di\Container->get('angellco\\spoon\\...', Array, Array)
#22 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/services/Plugins.php(897): yii\BaseYii::createObject(Array, Array)
#23 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/services/Plugins.php(230): craft\services\Plugins->createPlugin('spoon', Array)
#24 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/base/ApplicationTrait.php(1375): craft\services\Plugins->loadPlugins()
#25 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/web/Application.php(112): craft\web\Application->_postInit()
#26 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/base/BaseObject.php(109): craft\web\Application->init()
#27 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/base/Application.php(206): yii\base\BaseObject->__construct(Array)
#28 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/src/web/Application.php(100): yii\base\Application->__construct(Array)
#29 [internal function]: craft\web\Application->__construct(Array)
#30 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/di/Container.php(400): ReflectionClass->newInstanceArgs(Array)
#31 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/di/Container.php(159): yii\di\Container->build('craft\\web\\Appli...', Array, Array)
#32 /home/vagrant/eedc-exploreedmonton/vendor/yiisoft/yii2/BaseYii.php(351): yii\di\Container->get('craft\\web\\Appli...', Array, Array)
#33 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/bootstrap/bootstrap.php(244): yii\BaseYii::createObject(Array)
#34 /home/vagrant/eedc-exploreedmonton/vendor/craftcms/cms/bootstrap/web.php(52): require('/home/vagrant/e...')
#35 /home/vagrant/eedc-exploreedmonton/web/index.php(20): require('/home/vagrant/e...')
#36 {main}
@brandonkelly

This comment has been minimized.

Copy link
Member

@brandonkelly brandonkelly commented Dec 1, 2019

Can you both please upload your storage/runtime/compiled_classes/ContentBehavior.php file?

@ccchapman

This comment has been minimized.

Copy link
Author

@ccchapman ccchapman commented Dec 3, 2019

@brandonkelly Sure thing.

Here is is after the attempted upgrade:

<?php // vM7ocxTTwJ5lZ
/**
 * @link http://craftcms.com/
 * @copyright Copyright (c) Pixel & Tonic, Inc.
 * @license http://craftcms.com/license
 */

namespace craft\behaviors;

use yii\base\Behavior;

/**
 * Content behavior
 *
 * This class provides attributes for all the unique custom field handles.
 */
class ContentBehavior extends Behavior
{
    // Static
    // =========================================================================

    /**
     * @var string[] List of supported field handles.
     */
    public static $fieldHandles = [
    'mainBlock' => true,
    'headline' => true,
    'sidebarBlock' => true,
    'referenceCtaText' => true,
    'referenceDescription' => true,
    'referenceHeadline' => true,
    'referenceImage' => true,
    'notesNoSettings' => true,
    'notesSeoPending' => true,
    'notesHeroPending' => true,
    'notesReferenceDataExplanation' => true,
    'referenceAriaLabel' => true,
    'sectionBuilder' => true,
    'contentBuilder' => true,
    'tiles' => true,
    'sidebarBuilder' => true,
    'quicklinks' => true,
    'quicklink' => true,
    'tabs' => true,
    'tabHeading' => true,
    'tabContent' => true,
    'text' => true,
    'image' => true,
    'copy' => true,
    'sidebarPosition' => true,
    'layout' => true,
    'highlightLink' => true,
    'primaryCta' => true,
    'secondaryCta' => true,
    'helpReferenceData' => true,
    'story' => true,
    'trips' => true,
    'timeline' => true,
    'youtubeUrl' => true,
    'accordionItem' => true,
    'cta' => true,
    'subheadline' => true,
    'partners' => true,
    'partnerName' => true,
    'partnerLogo' => true,
    'partnerUrl' => true,
    'storyCategories' => true,
    'tripIntro' => true,
    'tripOverview' => true,
    'icon' => true,
    'startDate' => true,
    'endDate' => true,
    'donationAmount' => true,
    'partnerLevel' => true,
    'widget' => true,
    'referenceData' => true,
    'hero' => true,
    'headlinePlacement' => true,
    'subheroBannerHeadline' => true,
    'subheroBannerCta' => true,
    'keylineColour' => true,
    'seoShareDescription' => true,
    'seoKeywords' => true,
    'seoShareImage' => true,
    'seoShareImageDescription' => true,
    'altText' => true,
    'location' => true,
    'tripStatus' => true,
    'helpInterrupterCTA' => true,
    'locationName' => true,
    'locationAddress' => true,
    'locationPhoneNumber' => true,
    'locationEmail' => true,
    'locationWebsite' => true,
    'restoreLocation' => true,
    'locationShortId' => true,
    'globalLinks' => true,
    'linkLocation' => true,
    'linkLink' => true,
    'headerStyle' => true,
    'tripContentBuilder' => true,
    'tripHero' => true,
    'color' => true,
    'redirectUrl' => true,
    'freeformForm' => true,
    'successHeadline' => true,
    'successImage' => true,
    'successCta' => true,
    'newsCategories' => true,
    'alwaysShowSidebar' => true,
    ];

    // Properties
    // =========================================================================

/**
 * @var mixed Value for field with the handle “mainBlock”.
 */
public $mainBlock;

/**
 * @var mixed Value for field with the handle “headline”.
 */
public $headline;

/**
 * @var mixed Value for field with the handle “sidebarBlock”.
 */
public $sidebarBlock;

/**
 * @var mixed Value for field with the handle “referenceCtaText”.
 */
public $referenceCtaText;

/**
 * @var mixed Value for field with the handle “referenceDescription”.
 */
public $referenceDescription;

/**
 * @var mixed Value for field with the handle “referenceHeadline”.
 */
public $referenceHeadline;

/**
 * @var mixed Value for field with the handle “referenceImage”.
 */
public $referenceImage;

/**
 * @var mixed Value for field with the handle “notesNoSettings”.
 */
public $notesNoSettings;

/**
 * @var mixed Value for field with the handle “notesSeoPending”.
 */
public $notesSeoPending;

/**
 * @var mixed Value for field with the handle “notesHeroPending”.
 */
public $notesHeroPending;

/**
 * @var mixed Value for field with the handle “notesReferenceDataExplanation”.
 */
public $notesReferenceDataExplanation;

/**
 * @var mixed Value for field with the handle “referenceAriaLabel”.
 */
public $referenceAriaLabel;

/**
 * @var mixed Value for field with the handle “sectionBuilder”.
 */
public $sectionBuilder;

/**
 * @var mixed Value for field with the handle “contentBuilder”.
 */
public $contentBuilder;

/**
 * @var mixed Value for field with the handle “tiles”.
 */
public $tiles;

/**
 * @var mixed Value for field with the handle “sidebarBuilder”.
 */
public $sidebarBuilder;

/**
 * @var mixed Value for field with the handle “quicklinks”.
 */
public $quicklinks;

/**
 * @var mixed Value for field with the handle “quicklink”.
 */
public $quicklink;

/**
 * @var mixed Value for field with the handle “tabs”.
 */
public $tabs;

/**
 * @var mixed Value for field with the handle “tabHeading”.
 */
public $tabHeading;

/**
 * @var mixed Value for field with the handle “tabContent”.
 */
public $tabContent;

/**
 * @var mixed Value for field with the handle “text”.
 */
public $text;

/**
 * @var mixed Value for field with the handle “image”.
 */
public $image;

/**
 * @var mixed Value for field with the handle “copy”.
 */
public $copy;

/**
 * @var mixed Value for field with the handle “sidebarPosition”.
 */
public $sidebarPosition;

/**
 * @var mixed Value for field with the handle “layout”.
 */
public $layout;

/**
 * @var mixed Value for field with the handle “highlightLink”.
 */
public $highlightLink;

/**
 * @var mixed Value for field with the handle “primaryCta”.
 */
public $primaryCta;

/**
 * @var mixed Value for field with the handle “secondaryCta”.
 */
public $secondaryCta;

/**
 * @var mixed Value for field with the handle “helpReferenceData”.
 */
public $helpReferenceData;

/**
 * @var mixed Value for field with the handle “story”.
 */
public $story;

/**
 * @var mixed Value for field with the handle “trips”.
 */
public $trips;

/**
 * @var mixed Value for field with the handle “timeline”.
 */
public $timeline;

/**
 * @var mixed Value for field with the handle “youtubeUrl”.
 */
public $youtubeUrl;

/**
 * @var mixed Value for field with the handle “accordionItem”.
 */
public $accordionItem;

/**
 * @var mixed Value for field with the handle “cta”.
 */
public $cta;

/**
 * @var mixed Value for field with the handle “subheadline”.
 */
public $subheadline;

/**
 * @var mixed Value for field with the handle “partners”.
 */
public $partners;

/**
 * @var mixed Value for field with the handle “partnerName”.
 */
public $partnerName;

/**
 * @var mixed Value for field with the handle “partnerLogo”.
 */
public $partnerLogo;

/**
 * @var mixed Value for field with the handle “partnerUrl”.
 */
public $partnerUrl;

/**
 * @var mixed Value for field with the handle “storyCategories”.
 */
public $storyCategories;

/**
 * @var mixed Value for field with the handle “tripIntro”.
 */
public $tripIntro;

/**
 * @var mixed Value for field with the handle “tripOverview”.
 */
public $tripOverview;

/**
 * @var mixed Value for field with the handle “icon”.
 */
public $icon;

/**
 * @var mixed Value for field with the handle “startDate”.
 */
public $startDate;

/**
 * @var mixed Value for field with the handle “endDate”.
 */
public $endDate;

/**
 * @var mixed Value for field with the handle “donationAmount”.
 */
public $donationAmount;

/**
 * @var mixed Value for field with the handle “partnerLevel”.
 */
public $partnerLevel;

/**
 * @var mixed Value for field with the handle “widget”.
 */
public $widget;

/**
 * @var mixed Value for field with the handle “referenceData”.
 */
public $referenceData;

/**
 * @var mixed Value for field with the handle “hero”.
 */
public $hero;

/**
 * @var mixed Value for field with the handle “headlinePlacement”.
 */
public $headlinePlacement;

/**
 * @var mixed Value for field with the handle “subheroBannerHeadline”.
 */
public $subheroBannerHeadline;

/**
 * @var mixed Value for field with the handle “subheroBannerCta”.
 */
public $subheroBannerCta;

/**
 * @var mixed Value for field with the handle “keylineColour”.
 */
public $keylineColour;

/**
 * @var mixed Value for field with the handle “seoShareDescription”.
 */
public $seoShareDescription;

/**
 * @var mixed Value for field with the handle “seoKeywords”.
 */
public $seoKeywords;

/**
 * @var mixed Value for field with the handle “seoShareImage”.
 */
public $seoShareImage;

/**
 * @var mixed Value for field with the handle “seoShareImageDescription”.
 */
public $seoShareImageDescription;

/**
 * @var mixed Value for field with the handle “altText”.
 */
public $altText;

/**
 * @var mixed Value for field with the handle “location”.
 */
public $location;

/**
 * @var mixed Value for field with the handle “tripStatus”.
 */
public $tripStatus;

/**
 * @var mixed Value for field with the handle “helpInterrupterCTA”.
 */
public $helpInterrupterCTA;

/**
 * @var mixed Value for field with the handle “locationName”.
 */
public $locationName;

/**
 * @var mixed Value for field with the handle “locationAddress”.
 */
public $locationAddress;

/**
 * @var mixed Value for field with the handle “locationPhoneNumber”.
 */
public $locationPhoneNumber;

/**
 * @var mixed Value for field with the handle “locationEmail”.
 */
public $locationEmail;

/**
 * @var mixed Value for field with the handle “locationWebsite”.
 */
public $locationWebsite;

/**
 * @var mixed Value for field with the handle “restoreLocation”.
 */
public $restoreLocation;

/**
 * @var mixed Value for field with the handle “locationShortId”.
 */
public $locationShortId;

/**
 * @var mixed Value for field with the handle “globalLinks”.
 */
public $globalLinks;

/**
 * @var mixed Value for field with the handle “linkLocation”.
 */
public $linkLocation;

/**
 * @var mixed Value for field with the handle “linkLink”.
 */
public $linkLink;

/**
 * @var mixed Value for field with the handle “headerStyle”.
 */
public $headerStyle;

/**
 * @var mixed Value for field with the handle “tripContentBuilder”.
 */
public $tripContentBuilder;

/**
 * @var mixed Value for field with the handle “tripHero”.
 */
public $tripHero;

/**
 * @var mixed Value for field with the handle “color”.
 */
public $color;

/**
 * @var mixed Value for field with the handle “redirectUrl”.
 */
public $redirectUrl;

/**
 * @var mixed Value for field with the handle “freeformForm”.
 */
public $freeformForm;

/**
 * @var mixed Value for field with the handle “successHeadline”.
 */
public $successHeadline;

/**
 * @var mixed Value for field with the handle “successImage”.
 */
public $successImage;

/**
 * @var mixed Value for field with the handle “successCta”.
 */
public $successCta;

/**
 * @var mixed Value for field with the handle “newsCategories”.
 */
public $newsCategories;

/**
 * @var mixed Value for field with the handle “alwaysShowSidebar”.
 */
public $alwaysShowSidebar;

    /**
     * @var array Additional custom field values we don’t know about yet.
     */
    private $_customFieldValues = [];

    // Magic Property Methods
    // =========================================================================

    /**
     * @inheritdoc
     */
    public function __isset($name)
    {
        if (isset(self::$fieldHandles[$name])) {
            return true;
        }
        return parent::__isset($name);
    }

    /**
     * @inheritdoc
     */
    public function __get($name)
    {
        if (isset(self::$fieldHandles[$name])) {
            return $this->_customFieldValues[$name] ?? null;
        }
        return parent::__get($name);
    }

    /**
     * @inheritdoc
     */
    public function __set($name, $value)
    {
        if (isset(self::$fieldHandles[$name])) {
            $this->_customFieldValues[$name] = $value;
            return;
        }
        parent::__set($name, $value);
    }

    /**
     * @inheritdoc
     */
    public function canGetProperty($name, $checkVars = true)
    {
        if ($checkVars && isset(self::$fieldHandles[$name])) {
            return true;
        }
        return parent::canGetProperty($name, $checkVars);
    }

    /**
     * @inheritdoc
     */
    public function canSetProperty($name, $checkVars = true)
    {
        if ($checkVars && isset(self::$fieldHandles[$name])) {
            return true;
        }
        return parent::canSetProperty($name, $checkVars);
    }
}

Here is it before the upgrade:

<?php // vCAOhNMgeShAe
/**
 * @link http://craftcms.com/
 * @copyright Copyright (c) Pixel & Tonic, Inc.
 * @license http://craftcms.com/license
 */

namespace craft\behaviors;

use yii\base\Behavior;

/**
 * Content behavior
 *
 * This class provides attributes for all the unique custom field handles.
 */
class ContentBehavior extends Behavior
{
    // Static
    // =========================================================================

    /**
     * @var string[] List of supported field handles.
     */
    public static $fieldHandles = [
        'mainBlock' => true,
        'headline' => true,
        'sidebarBlock' => true,
        'referenceCtaText' => true,
        'referenceDescription' => true,
        'referenceHeadline' => true,
        'referenceImage' => true,
        'notesNoSettings' => true,
        'notesSeoPending' => true,
        'notesHeroPending' => true,
        'notesReferenceDataExplanation' => true,
        'referenceAriaLabel' => true,
        'sectionBuilder' => true,
        'contentBuilder' => true,
        'tiles' => true,
        'sidebarBuilder' => true,
        'quicklinks' => true,
        'quicklink' => true,
        'tabs' => true,
        'tabHeading' => true,
        'tabContent' => true,
        'text' => true,
        'image' => true,
        'copy' => true,
        'sidebarPosition' => true,
        'layout' => true,
        'highlightLink' => true,
        'primaryCta' => true,
        'secondaryCta' => true,
        'helpReferenceData' => true,
        'story' => true,
        'trips' => true,
        'timeline' => true,
        'youtubeUrl' => true,
        'accordionItem' => true,
        'cta' => true,
        'subheadline' => true,
        'partners' => true,
        'partnerName' => true,
        'partnerLogo' => true,
        'partnerUrl' => true,
        'storyCategories' => true,
        'tripIntro' => true,
        'tripOverview' => true,
        'icon' => true,
        'startDate' => true,
        'endDate' => true,
        'donationAmount' => true,
        'partnerLevel' => true,
        'widget' => true,
        'referenceData' => true,
        'hero' => true,
        'headlinePlacement' => true,
        'subheroBannerHeadline' => true,
        'subheroBannerCta' => true,
        'keylineColour' => true,
        'seoShareDescription' => true,
        'seoKeywords' => true,
        'seoShareImage' => true,
        'seoShareImageDescription' => true,
        'altText' => true,
        'location' => true,
        'tripStatus' => true,
        'helpInterrupterCTA' => true,
        'locationName' => true,
        'locationAddress' => true,
        'locationPhoneNumber' => true,
        'locationEmail' => true,
        'locationWebsite' => true,
        'restoreLocation' => true,
        'locationShortId' => true,
        'globalLinks' => true,
        'linkLocation' => true,
        'linkLink' => true,
        'headerStyle' => true,
        'tripContentBuilder' => true,
        'tripHero' => true,
        'color' => true,
        'redirectUrl' => true,
        'freeformForm' => true,
        'successHeadline' => true,
        'successImage' => true,
        'successCta' => true,
        'newsCategories' => true,
        'alwaysShowSidebar' => true,
    ];

    // Properties
    // =========================================================================

    /**
     * @var \craft\elements\db\MatrixBlockQuery Value for field with the handle “mainBlock”.
     */
    public $mainBlock;

    /**
     * @var string|null Value for field with the handle “headline”.
     */
    public $headline;

    /**
     * @var \craft\elements\db\MatrixBlockQuery Value for field with the handle “sidebarBlock”.
     */
    public $sidebarBlock;

    /**
     * @var string|null Value for field with the handle “referenceCtaText”.
     */
    public $referenceCtaText;

    /**
     * @var string|null Value for field with the handle “referenceDescription”.
     */
    public $referenceDescription;

    /**
     * @var string|null Value for field with the handle “referenceHeadline”.
     */
    public $referenceHeadline;

    /**
     * @var \craft\elements\db\AssetQuery Value for field with the handle “referenceImage”.
     */
    public $referenceImage;

    /**
     * @var mixed Value for field with the handle “notesNoSettings”.
     */
    public $notesNoSettings;

    /**
     * @var mixed Value for field with the handle “notesSeoPending”.
     */
    public $notesSeoPending;

    /**
     * @var mixed Value for field with the handle “notesHeroPending”.
     */
    public $notesHeroPending;

    /**
     * @var mixed Value for field with the handle “notesReferenceDataExplanation”.
     */
    public $notesReferenceDataExplanation;

    /**
     * @var string|null Value for field with the handle “referenceAriaLabel”.
     */
    public $referenceAriaLabel;

    /**
     * @var mixed Value for field with the handle “sectionBuilder”.
     */
    public $sectionBuilder;

    /**
     * @var \craft\elements\db\MatrixBlockQuery Value for field with the handle “contentBuilder”.
     */
    public $contentBuilder;

    /**
     * @var \verbb\supertable\elements\db\SuperTableBlockQuery Value for field with the handle “tiles”.
     */
    public $tiles;

    /**
     * @var \craft\elements\db\MatrixBlockQuery Value for field with the handle “sidebarBuilder”.
     */
    public $sidebarBuilder;

    /**
     * @var \verbb\supertable\elements\db\SuperTableBlockQuery Value for field with the handle “quicklinks”.
     */
    public $quicklinks;

    /**
     * @var mixed Value for field with the handle “quicklink”.
     */
    public $quicklink;

    /**
     * @var \craft\elements\db\EntryQuery Value for field with the handle “tabs”.
     */
    public $tabs;

    /**
     * @var string|null Value for field with the handle “tabHeading”.
     */
    public $tabHeading;

    /**
     * @var \craft\elements\db\MatrixBlockQuery Value for field with the handle “tabContent”.
     */
    public $tabContent;

    /**
     * @var mixed Value for field with the handle “text”.
     */
    public $text;

    /**
     * @var \craft\elements\db\AssetQuery Value for field with the handle “image”.
     */
    public $image;

    /**
     * @var mixed|string|null Value for field with the handle “copy”.
     */
    public $copy;

    /**
     * @var mixed Value for field with the handle “sidebarPosition”.
     */
    public $sidebarPosition;

    /**
     * @var \craft\fields\data\SingleOptionFieldData Value for field with the handle “layout”.
     */
    public $layout;

    /**
     * @var bool Value for field with the handle “highlightLink”.
     */
    public $highlightLink;

    /**
     * @var mixed Value for field with the handle “primaryCta”.
     */
    public $primaryCta;

    /**
     * @var mixed Value for field with the handle “secondaryCta”.
     */
    public $secondaryCta;

    /**
     * @var mixed Value for field with the handle “helpReferenceData”.
     */
    public $helpReferenceData;

    /**
     * @var \craft\elements\db\EntryQuery Value for field with the handle “story”.
     */
    public $story;

    /**
     * @var \craft\elements\db\EntryQuery Value for field with the handle “trips”.
     */
    public $trips;

    /**
     * @var array|null Value for field with the handle “timeline”.
     */
    public $timeline;

    /**
     * @var mixed Value for field with the handle “youtubeUrl”.
     */
    public $youtubeUrl;

    /**
     * @var \verbb\supertable\elements\db\SuperTableBlockQuery Value for field with the handle “accordionItem”.
     */
    public $accordionItem;

    /**
     * @var mixed Value for field with the handle “cta”.
     */
    public $cta;

    /**
     * @var string|null Value for field with the handle “subheadline”.
     */
    public $subheadline;

    /**
     * @var \craft\elements\db\CategoryQuery Value for field with the handle “partners”.
     */
    public $partners;

    /**
     * @var string|null Value for field with the handle “partnerName”.
     */
    public $partnerName;

    /**
     * @var \craft\elements\db\AssetQuery Value for field with the handle “partnerLogo”.
     */
    public $partnerLogo;

    /**
     * @var string|null Value for field with the handle “partnerUrl”.
     */
    public $partnerUrl;

    /**
     * @var \craft\elements\db\CategoryQuery Value for field with the handle “storyCategories”.
     */
    public $storyCategories;

    /**
     * @var string|null Value for field with the handle “tripIntro”.
     */
    public $tripIntro;

    /**
     * @var \verbb\supertable\elements\db\SuperTableBlockQuery Value for field with the handle “tripOverview”.
     */
    public $tripOverview;

    /**
     * @var \craft\elements\db\CategoryQuery|\craft\elements\db\AssetQuery Value for field with the handle “icon”.
     */
    public $icon;

    /**
     * @var DateTime|null Value for field with the handle “startDate”.
     */
    public $startDate;

    /**
     * @var DateTime|null Value for field with the handle “endDate”.
     */
    public $endDate;

    /**
     * @var string|null Value for field with the handle “donationAmount”.
     */
    public $donationAmount;

    /**
     * @var \craft\elements\db\CategoryQuery Value for field with the handle “partnerLevel”.
     */
    public $partnerLevel;

    /**
     * @var \craft\fields\data\SingleOptionFieldData Value for field with the handle “widget”.
     */
    public $widget;

    /**
     * @var mixed Value for field with the handle “referenceData”.
     */
    public $referenceData;

    /**
     * @var \craft\elements\db\MatrixBlockQuery Value for field with the handle “hero”.
     */
    public $hero;

    /**
     * @var \craft\fields\data\SingleOptionFieldData Value for field with the handle “headlinePlacement”.
     */
    public $headlinePlacement;

    /**
     * @var string|null Value for field with the handle “subheroBannerHeadline”.
     */
    public $subheroBannerHeadline;

    /**
     * @var \verbb\supertable\elements\db\SuperTableBlockQuery Value for field with the handle “subheroBannerCta”.
     */
    public $subheroBannerCta;

    /**
     * @var \craft\fields\data\SingleOptionFieldData Value for field with the handle “keylineColour”.
     */
    public $keylineColour;

    /**
     * @var string|null Value for field with the handle “seoShareDescription”.
     */
    public $seoShareDescription;

    /**
     * @var string|null Value for field with the handle “seoKeywords”.
     */
    public $seoKeywords;

    /**
     * @var \craft\elements\db\AssetQuery Value for field with the handle “seoShareImage”.
     */
    public $seoShareImage;

    /**
     * @var string|null Value for field with the handle “seoShareImageDescription”.
     */
    public $seoShareImageDescription;

    /**
     * @var string|null Value for field with the handle “altText”.
     */
    public $altText;

    /**
     * @var \craft\elements\db\CategoryQuery Value for field with the handle “location”.
     */
    public $location;

    /**
     * @var string|null Value for field with the handle “tripStatus”.
     */
    public $tripStatus;

    /**
     * @var mixed Value for field with the handle “helpInterrupterCTA”.
     */
    public $helpInterrupterCTA;

    /**
     * @var string|null Value for field with the handle “locationName”.
     */
    public $locationName;

    /**
     * @var mixed Value for field with the handle “locationAddress”.
     */
    public $locationAddress;

    /**
     * @var string|null Value for field with the handle “locationPhoneNumber”.
     */
    public $locationPhoneNumber;

    /**
     * @var string|null Value for field with the handle “locationEmail”.
     */
    public $locationEmail;

    /**
     * @var string|null Value for field with the handle “locationWebsite”.
     */
    public $locationWebsite;

    /**
     * @var \craft\elements\db\EntryQuery Value for field with the handle “restoreLocation”.
     */
    public $restoreLocation;

    /**
     * @var string|null Value for field with the handle “locationShortId”.
     */
    public $locationShortId;

    /**
     * @var \verbb\supertable\elements\db\SuperTableBlockQuery Value for field with the handle “globalLinks”.
     */
    public $globalLinks;

    /**
     * @var \craft\fields\data\SingleOptionFieldData Value for field with the handle “linkLocation”.
     */
    public $linkLocation;

    /**
     * @var mixed Value for field with the handle “linkLink”.
     */
    public $linkLink;

    /**
     * @var \craft\fields\data\SingleOptionFieldData Value for field with the handle “headerStyle”.
     */
    public $headerStyle;

    /**
     * @var mixed Value for field with the handle “tripContentBuilder”.
     */
    public $tripContentBuilder;

    /**
     * @var \verbb\supertable\elements\db\SuperTableBlockQuery Value for field with the handle “tripHero”.
     */
    public $tripHero;

    /**
     * @var \craft\fields\data\SingleOptionFieldData Value for field with the handle “color”.
     */
    public $color;

    /**
     * @var mixed Value for field with the handle “redirectUrl”.
     */
    public $redirectUrl;

    /**
     * @var mixed Value for field with the handle “freeformForm”.
     */
    public $freeformForm;

    /**
     * @var string|null Value for field with the handle “successHeadline”.
     */
    public $successHeadline;

    /**
     * @var \craft\elements\db\AssetQuery Value for field with the handle “successImage”.
     */
    public $successImage;

    /**
     * @var mixed Value for field with the handle “successCta”.
     */
    public $successCta;

    /**
     * @var \craft\elements\db\CategoryQuery Value for field with the handle “newsCategories”.
     */
    public $newsCategories;

    /**
     * @var bool Value for field with the handle “alwaysShowSidebar”.
     */
    public $alwaysShowSidebar;

    /**
     * @var array Additional custom field values we don’t know about yet.
     */
    private $_customFieldValues = [];

    // Magic Property Methods
    // =========================================================================

    /**
     * @inheritdoc
     */
    public function __isset($name)
    {
        if (isset(self::$fieldHandles[$name])) {
            return true;
        }
        return parent::__isset($name);
    }

    /**
     * @inheritdoc
     */
    public function __get($name)
    {
        if (isset(self::$fieldHandles[$name])) {
            return $this->_customFieldValues[$name] ?? null;
        }
        return parent::__get($name);
    }

    /**
     * @inheritdoc
     */
    public function __set($name, $value)
    {
        if (isset(self::$fieldHandles[$name])) {
            $this->_customFieldValues[$name] = $value;
            return;
        }
        parent::__set($name, $value);
    }

    /**
     * @inheritdoc
     */
    public function canGetProperty($name, $checkVars = true)
    {
        if ($checkVars && isset(self::$fieldHandles[$name])) {
            return true;
        }
        return parent::canGetProperty($name, $checkVars);
    }

    /**
     * @inheritdoc
     */
    public function canSetProperty($name, $checkVars = true)
    {
        if ($checkVars && isset(self::$fieldHandles[$name])) {
            return true;
        }
        return parent::canSetProperty($name, $checkVars);
    }
}
@brandonkelly

This comment has been minimized.

Copy link
Member

@brandonkelly brandonkelly commented Dec 3, 2019

@ccchapman And you’re getting a PHP error with that “after” file? Not seeing anything wrong with it.

@ccchapman

This comment has been minimized.

Copy link
Author

@ccchapman ccchapman commented Dec 3, 2019

@brandonkelly Yes, that is correct.

@brandonkelly

This comment has been minimized.

Copy link
Member

@brandonkelly brandonkelly commented Dec 3, 2019

Can you send your composer.json and composer.lock files and a database backup over to support@craftcms.com?

@ccchapman

This comment has been minimized.

Copy link
Author

@ccchapman ccchapman commented Dec 4, 2019

@brandonkelly Done!

Not sure if relevant, but this issue occurs when upgrading originally from 3.0.x. Manually jumping to each breakpoint/minor version. I also got this on a site upgrading from 3.3.15 to 3.3.17.

@brandonkelly

This comment has been minimized.

Copy link
Member

@brandonkelly brandonkelly commented Dec 10, 2019

I believe we may have finally gotten to the bottom of this error. Would you mind testing?

To get the fix early, change your craftcms/cms requirement in composer.json to:

"require": {
  "craftcms/cms": "dev-develop#e20eceb803c75ad6dbe2e2db537be544835e3975 as 3.3.17",
  "...": "..."
}

Then run composer update.

@brandonkelly

This comment has been minimized.

Copy link
Member

@brandonkelly brandonkelly commented Dec 10, 2019

3.3.18 is out with that fix now, and another.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.