Hello,
I run a website where the theme came with 8.x-1.0-alpha1+2-dev from May 21, 2016. If I try and update it to 8.x-4.0-beta2, I get a lot of undefined index warnings.
Notice: Undefined index: context_id in Drupal\context\Plugin\ContextReaction\Blocks->execute() (line 220 of /home/drupal/public_html/modules/context/src/Plugin/ContextReaction/Blocks.php) #0
Notice: Undefined index: css_class in Drupal\context\Plugin\ContextReaction\Blocks->execute() (line 195 of /home/drupal/public_html/modules/context/src/Plugin/ContextReaction/Blocks.php) #0
I had to role back to the previous version until I can get this sorted out.
Context is a module we actively use, and I don't like running such an old version. It is the only thing I haven't been able to update :)
Running Drupal 8.6.3, and PHP 7.0.32.
Comments
Comment #2
networkdawg commentedComment #3
boshtian commentedHave you run
drush updbafter the update?Both context_id and css_class configurations are added through update hooks 8001 and 8002.
Comment #4
networkdawg commentedI did try running that, and it says no database updates.
When I ran composer to install the later version, it didn't do database updates either. So if I install the new version, I get those messages still.
Is there a way I can manually create those indexes?
Comment #5
deaom commentedHi @networkdawg. When you update the modules always do the drush updb or via your browser run the yoursitedomain/update.php to get all the updates that were added to the modules. Are you still seeing the notices?
Comment #6
networkdawg commentedHello,
Yes I just tried the update again, and I am still seeing these messages over and over. I tried drush updb as well as update.php and it says no updates needed.
Comment #7
deaom commentedHi @networkdawg could you try updating to dev version, just to see if the
drush updbreturns any updates and if the problem remains?If with updating to dev version results in no notices, then try to downgrade it back to the beta2 version to see if the notices are gone or if they re-appear.
Comment #8
deaom commentedTry running the update hooks manually one by one:
drush php-eval "module_load_install('context'); context_update_NUMBER();"So you need to change the NUMBER to update hook number (8001, 8002, 8003).
Comment #9
deaom commentedI'm gonna close this issue as outdated as the beta5 version is already out and there were some not so small code changes that were added and also, there was no new activity/response.