Closed (fixed)
Project:
Charts
Version:
5.0.x-dev
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
5 Apr 2022 at 00:55 UTC
Updated:
19 Apr 2022 at 14:19 UTC
Jump to comment: Most recent
Have this running on my local (Windows, PHP 7.4) but when migrating to server (centos, php7.4) the site is dead. When i try to run drush cr i get:
[error] ParseError: syntax error, unexpected ')' in Composer\Autoload\includeFile() (line 146 of /home/nzenzen/public_html/staging/web/modules/contrib/charts/src/Plugin/views/style/ChartsPluginStyleChart.php) #0 /home/nzenzen/public_html/staging/vendor/composer/ClassLoader.php(428): Composer\Autoload\includeFile('/home/nzenzen/p...')
#1 [internal function]: Composer\Autoload\ClassLoader->loadClass('Drupal\\charts\\P...')
#2 [internal function]: spl_autoload_call('Drupal\\charts\\P...')
#3 /home/nzenzen/public_html/staging/web/core/lib/Drupal/Component/Plugin/Factory/DefaultFactory.php(96): class_exists('Drupal\\charts\\P...')
#4 /home/nzenzen/public_html/staging/web/core/lib/Drupal/Core/Plugin/Factory/ContainerFactory.php(17): Drupal\Component\Plugin\Factory\DefaultFactory::getPluginClass('chart', Array, 'Drupal\\views\\Pl...')
#5 /home/nzenzen/public_html/staging/web/core/lib/Drupal/Component/Plugin/PluginManagerBase.php(83): Drupal\Core\Plugin\Factory\ContainerFactory->createInstance('chart', Array)
#6 /home/nzenzen/public_html/staging/web/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php(817): Drupal\Component\Plugin\PluginManagerBase->createInstance('chart')
#7 /home/nzenzen/public_html/staging/web/core/modules/views/src/ViewExecutable.php(891): Drupal\views\Plugin\views\display\DisplayPluginBase->getPlugin('style')
#8 /home/nzenzen/public_html/staging/web/core/modules/views/src/ViewExecutable.php(871): Drupal\views\ViewExecutable->initStyle()
#9 /home/nzenzen/public_html/staging/web/core/modules/views/src/Plugin/views/field/FieldPluginBase.php(434): Drupal\views\ViewExecutable->getStyle()
#10 /home/nzenzen/public_html/staging/web/core/modules/views/src/Plugin/views/field/NumericField.php(27): Drupal\views\Plugin\views\field\FieldPluginBase->defineOptions()
#11 /home/nzenzen/public_html/staging/web/core/modules/views/src/Plugin/views/PluginBase.php(139): Drupal\views\Plugin\views\field\NumericField->defineOptions()
#12 /home/nzenzen/public_html/staging/web/core/modules/views/src/Plugin/views/HandlerBase.php(102): Drupal\views\Plugin\views\PluginBase->init(Object(Drupal\views\ViewExecutable), Object(Drupal\views\Plugin\views\display\DefaultDisplay), Array)
#13 /home/nzenzen/public_html/staging/web/core/modules/views/src/Plugin/views/field/FieldPluginBase.php(117): Drupal\views\Plugin\views\HandlerBase->init(Object(Drupal\views\ViewExecutable), Object(Drupal\views\Plugin\views\display\DefaultDisplay), Array)
#14 /home/nzenzen/public_html/staging/web/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php(895): Drupal\views\Plugin\views\field\FieldPluginBase->init(Object(Drupal\views\ViewExecutable), Object(Drupal\views\Plugin\views\display\DefaultDisplay), Array)
#15 /home/nzenzen/public_html/staging/web/core/modules/views/src/Entity/View.php(553): Drupal\views\Plugin\views\display\DisplayPluginBase->getHandlers('field')
#16 /home/nzenzen/public_html/staging/web/core/lib/Drupal/Core/Config/ConfigManager.php(494): Drupal\views\Entity\View->onDependencyRemoval(Array)
#17 /home/nzenzen/public_html/staging/web/core/lib/Drupal/Core/Config/ConfigManager.php(357): Drupal\Core\Config\ConfigManager->callOnDependencyRemoval(Object(Drupal\views\Entity\View), Array, 'module', Array)
#18 /home/nzenzen/public_html/staging/web/core/lib/Drupal/Core/Config/ConfigManager.php(218): Drupal\Core\Config\ConfigManager->getConfigEntitiesToChangeOnDependencyRemoval('module', Array, false)
Cant do anything now. Cant disable the module with drush.
This was originally with 5-alpha3 but saw someone report similar error and it says fixed in -dev, so switched to dev but no luck.
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
andileco commentedTry requiring DEV again, making sure you instruct Composer to reinstall Charts. There's not even a character on that line anymore, so I think you're facing some sort of cache, etc.
Comment #3
liquidcms commentedjust looked directly in the zip file that looks like it was created today and i see this:
and removing the last comma and i can no uninstall the module.
Comment #4
liquidcms commentedand then once that's fixed:
[error] ParseError: syntax error, unexpected ')' in Composer\Autoload\includeFile() (line 93 of /home/nzenzen/public_html/staging/web/modules/contrib/charts/src/Element/Chart.php) #0 /home/nzenzen/public_html/staging/vendor/composer/ClassLoader.php(428): Composer\Autoload\includeFile('/home/nzenzen/p...')fixing this one and then module seems to install properly.
Comment #8
andileco commented@liquidcms, can you pull the latest and report back if it's working now?
Comment #9
liquidcms commentedYes, fixed now. Thanks.
Comment #10
andileco commentedThank you, and apologies. I will add some tests to ensure this does happen again.