🇵🇹Portugal LuisPimentelLopes Lisbon 🇵🇹🇪🇺
#5 also worked for me. Thank you @ericdsd
🇵🇹Portugal LuisPimentelLopes Lisbon 🇵🇹🇪🇺
Previous patches didn't work with 10.3, adding a compatible patch.
🇵🇹Portugal LuisPimentelLopes Lisbon 🇵🇹🇪🇺
Hi, I also installed Storybook with Drupal integration with the reproduction steps and got the same issue but on the 2.0.0-alpha1.
After a quick debug, it seems the controller is trying to create an instance of a plugin that doesn't exists.
/**
* Creates an instance.
*
* @throws \Drupal\sdc\Exception\ComponentNotFoundException
*
* @internal
*/
public function createInstance($plugin_id, array $configuration = []): Component {
$configuration['app_root'] = $this->appRoot;
$configuration['enforce_schemas'] = $this->shouldEnforceSchemas(
$this->definitions[$plugin_id] ?? []
);
try {
$instance = parent::createInstance($plugin_id, $configuration);
if (!$instance instanceof Component) {
throw new ComponentNotFoundException(sprintf(
'Unable to find component "%s" in the component repository.',
$plugin_id,
));
}
return $instance;
}
catch (PluginException $e) {
// Cast the PluginNotFound to a more specific exception.
$message = sprintf(
'Unable to find component "%s" in the component repository. [%s]',
$plugin_id,
$e->getMessage()
);
throw new ComponentNotFoundException($message, $e->getCode(), $e);
}
}