Upgrade 1-11.38

This commit is contained in:
xesmyd
2026-03-30 14:10:30 +02:00
parent f2a7e6d1fc
commit ac648ef29d
24665 changed files with 69682 additions and 2205004 deletions
+5
View File
@@ -1,6 +1,11 @@
CHANGELOG
=========
3.3.0
-----
* Deprecated `ContainerAwareRuntimeLoader`
2.7.0
-----
@@ -11,11 +11,13 @@
namespace Symfony\Bundle\TwigBundle\CacheWarmer;
use Psr\Container\ContainerInterface;
use Symfony\Component\DependencyInjection\ServiceSubscriberInterface;
use Symfony\Component\Finder\Finder;
use Symfony\Component\HttpKernel\CacheWarmer\CacheWarmerInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
use Symfony\Bundle\FrameworkBundle\CacheWarmer\TemplateFinderInterface;
use Symfony\Component\Templating\TemplateReference;
use Twig\Environment;
use Twig\Error\Error;
/**
@@ -26,18 +28,14 @@ use Twig\Error\Error;
*
* @author Fabien Potencier <fabien@symfony.com>
*/
class TemplateCacheCacheWarmer implements CacheWarmerInterface
class TemplateCacheCacheWarmer implements CacheWarmerInterface, ServiceSubscriberInterface
{
protected $container;
protected $finder;
private $paths;
/**
* Constructor.
*
* @param ContainerInterface $container The dependency injection container
* @param TemplateFinderInterface $finder The template paths cache warmer
* @param array $paths Additional twig paths to warm
* @param array $paths Additional twig paths to warm
*/
public function __construct(ContainerInterface $container, TemplateFinderInterface $finder = null, array $paths = array())
{
@@ -93,6 +91,16 @@ class TemplateCacheCacheWarmer implements CacheWarmerInterface
return true;
}
/**
* {@inheritdoc}
*/
public static function getSubscribedServices()
{
return array(
'twig' => Environment::class,
);
}
/**
* Find templates in the given directory.
*
@@ -11,6 +11,8 @@
namespace Symfony\Bundle\TwigBundle;
@trigger_error(sprintf('The %s class is deprecated since Symfony 3.3 and will be removed in 4.0. Use the Twig\RuntimeLoader\ContainerRuntimeLoader class instead.', ContainerAwareRuntimeLoader::class), E_USER_DEPRECATED);
use Psr\Log\LoggerInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
use Twig\RuntimeLoader\RuntimeLoaderInterface;
@@ -19,6 +21,8 @@ use Twig\RuntimeLoader\RuntimeLoaderInterface;
* Loads Twig extension runtimes via the service container.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated since version 3.3, will be removed in 4.0. Use \Twig\Loader\ContainerRuntimeLoader instead.
*/
class ContainerAwareRuntimeLoader implements RuntimeLoaderInterface
{
@@ -29,12 +29,12 @@ use Twig\Loader\ExistsLoaderInterface;
class ExceptionController
{
protected $twig;
/**
* @var bool Show error (false) or exception (true) pages by default
*/
protected $debug;
/**
* @param Environment $twig
* @param bool $debug Show error (false) or exception (true) pages by default
*/
public function __construct(Environment $twig, $debug)
{
$this->twig = $twig;
@@ -48,10 +48,6 @@ class ExceptionController
* the exception page (when true). If it is not present, the "debug" value passed into the constructor will
* be used.
*
* @param Request $request The request
* @param FlattenException $exception A FlattenException instance
* @param DebugLoggerInterface $logger A DebugLoggerInterface instance
*
* @return Response
*
* @throws \InvalidArgumentException When the exception template does not exist
@@ -11,15 +11,11 @@
namespace Symfony\Bundle\TwigBundle\DependencyInjection\Compiler;
use Symfony\Component\Config\Resource\ClassExistenceResource;
use Symfony\Component\DependencyInjection\Alias;
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Reference;
use Symfony\Component\ExpressionLanguage\ExpressionLanguage;
use Symfony\Component\Stopwatch\Stopwatch;
use Symfony\Component\Workflow\Workflow;
use Symfony\Component\Yaml\Parser as YamlParser;
/**
* @author Jean-François Simon <jeanfrancois.simon@sensiolabs.com>
@@ -50,7 +46,14 @@ class ExtensionPass implements CompilerPassInterface
if ($container->has('form.extension')) {
$container->getDefinition('twig.extension.form')->addTag('twig.extension');
$reflClass = new \ReflectionClass('Symfony\Bridge\Twig\Extension\FormExtension');
$container->getDefinition('twig.loader.native_filesystem')->addMethodCall('addPath', array(dirname(dirname($reflClass->getFileName())).'/Resources/views/Form'));
$coreThemePath = dirname(dirname($reflClass->getFileName())).'/Resources/views/Form';
$container->getDefinition('twig.loader.native_filesystem')->addMethodCall('addPath', array($coreThemePath));
$paths = $container->getDefinition('twig.cache_warmer')->getArgument(2);
$paths[$coreThemePath] = null;
$container->getDefinition('twig.cache_warmer')->replaceArgument(2, $paths);
$container->getDefinition('twig.template_iterator')->replaceArgument(2, $paths);
}
if ($container->has('translator')) {
@@ -79,19 +82,20 @@ class ExtensionPass implements CompilerPassInterface
if ($container->getParameter('kernel.debug')) {
$container->getDefinition('twig.extension.profiler')->addTag('twig.extension');
$container->getDefinition('twig.extension.debug')->addTag('twig.extension');
// only register if the improved version from DebugBundle is *not* present
if (!$container->has('twig.extension.dump')) {
$container->getDefinition('twig.extension.debug')->addTag('twig.extension');
}
}
$composerRootDir = $this->getComposerRootDir($container->getParameter('kernel.root_dir'));
$twigLoader = $container->getDefinition('twig.loader.native_filesystem');
if ($container->has('templating')) {
$loader = $container->getDefinition('twig.loader.filesystem');
$loader->setMethodCalls(array_merge($twigLoader->getMethodCalls(), $loader->getMethodCalls()));
$loader->replaceArgument(2, $composerRootDir);
$twigLoader->clearTag('twig.loader');
} else {
$twigLoader->replaceArgument(1, $composerRootDir);
$container->setAlias('twig.loader.filesystem', new Alias('twig.loader.native_filesystem', false));
$container->removeDefinition('templating.engine.twig');
}
@@ -100,40 +104,22 @@ class ExtensionPass implements CompilerPassInterface
$container->getDefinition('twig.extension.assets')->addTag('twig.extension');
}
$container->addResource(new ClassExistenceResource(YamlParser::class));
if (class_exists(YamlParser::class)) {
if ($container->hasDefinition('twig.extension.yaml')) {
$container->getDefinition('twig.extension.yaml')->addTag('twig.extension');
}
$container->addResource(new ClassExistenceResource(Stopwatch::class));
if (class_exists(Stopwatch::class)) {
if (class_exists('Symfony\Component\Stopwatch\Stopwatch')) {
$container->getDefinition('twig.extension.debug.stopwatch')->addTag('twig.extension');
}
$container->addResource(new ClassExistenceResource(ExpressionLanguage::class));
if (class_exists(ExpressionLanguage::class)) {
if ($container->hasDefinition('twig.extension.expression')) {
$container->getDefinition('twig.extension.expression')->addTag('twig.extension');
}
$container->addResource(new ClassExistenceResource(Workflow::class));
if (!class_exists(Workflow::class) || !$container->has('workflow.registry')) {
$container->removeDefinition('workflow.twig_extension');
} else {
$container->getDefinition('workflow.twig_extension')->addTag('twig.extension');
}
}
private function getComposerRootDir($rootDir)
{
$dir = $rootDir;
while (!file_exists($dir.'/composer.json')) {
if ($dir === dirname($dir)) {
return $rootDir;
}
$dir = dirname($dir);
}
return $dir;
}
}
@@ -13,7 +13,8 @@ namespace Symfony\Bundle\TwigBundle\DependencyInjection\Compiler;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
use Symfony\Component\DependencyInjection\Exception\InvalidArgumentException;
use Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass;
use Symfony\Component\DependencyInjection\Reference;
/**
* Registers Twig runtime services.
@@ -28,20 +29,11 @@ class RuntimeLoaderPass implements CompilerPassInterface
$definition = $container->getDefinition('twig.runtime_loader');
$mapping = array();
foreach ($container->findTaggedServiceIds('twig.runtime') as $id => $attributes) {
foreach ($container->findTaggedServiceIds('twig.runtime', true) as $id => $attributes) {
$def = $container->getDefinition($id);
if (!$def->isPublic()) {
throw new InvalidArgumentException(sprintf('The service "%s" must be public as it can be lazy-loaded.', $id));
}
if ($def->isAbstract()) {
throw new InvalidArgumentException(sprintf('The service "%s" must not be abstract as it can be lazy-loaded.', $id));
}
$mapping[$def->getClass()] = $id;
$mapping[$def->getClass()] = new Reference($id);
}
$definition->replaceArgument(1, $mapping);
$definition->replaceArgument(0, ServiceLocatorTagPass::register($container, $mapping));
}
}
@@ -36,7 +36,7 @@ class TwigEnvironmentPass implements CompilerPassInterface
// be registered.
$calls = $definition->getMethodCalls();
$definition->setMethodCalls(array());
foreach ($container->findTaggedServiceIds('twig.extension') as $id => $attributes) {
foreach ($container->findTaggedServiceIds('twig.extension', true) as $id => $attributes) {
$definition->addMethodCall('addExtension', array(new Reference($id)));
}
$definition->setMethodCalls(array_merge($definition->getMethodCalls(), $calls));
@@ -32,7 +32,7 @@ class TwigLoaderPass implements CompilerPassInterface
$prioritizedLoaders = array();
$found = 0;
foreach ($container->findTaggedServiceIds('twig.loader') as $id => $attributes) {
foreach ($container->findTaggedServiceIds('twig.loader', true) as $id => $attributes) {
$priority = isset($attributes[0]['priority']) ? $attributes[0]['priority'] : 0;
$prioritizedLoaders[$priority][] = $id;
++$found;
@@ -11,12 +11,16 @@
namespace Symfony\Bundle\TwigBundle\DependencyInjection;
use Symfony\Bridge\Twig\Extension\WebLinkExtension;
use Symfony\Component\Config\FileLocator;
use Symfony\Component\Config\Resource\FileExistenceResource;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Reference;
use Symfony\Component\DependencyInjection\Loader\XmlFileLoader;
use Symfony\Component\HttpKernel\DependencyInjection\Extension;
use Symfony\Component\WebLink\HttpHeaderSerializer;
use Twig\Extension\ExtensionInterface;
use Twig\Loader\LoaderInterface;
/**
* TwigExtension.
@@ -26,12 +30,6 @@ use Symfony\Component\HttpKernel\DependencyInjection\Extension;
*/
class TwigExtension extends Extension
{
/**
* Responds to the twig configuration parameter.
*
* @param array $configs
* @param ContainerBuilder $container
*/
public function load(array $configs, ContainerBuilder $container)
{
$loader = new XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
@@ -49,6 +47,13 @@ class TwigExtension extends Extension
$container->removeDefinition('twig.translation.extractor');
}
if (class_exists(HttpHeaderSerializer::class)) {
$definition = $container->register('twig.extension.weblink', WebLinkExtension::class);
$definition->setPublic(false);
$definition->addArgument(new Reference('request_stack'));
$definition->addTag('twig.extension');
}
foreach ($configs as $key => $config) {
if (isset($config['globals'])) {
foreach ($config['globals'] as $name => $value) {
@@ -89,6 +94,7 @@ class TwigExtension extends Extension
}
}
// paths are modified in ExtensionPass if forms are enabled
$container->getDefinition('twig.cache_warmer')->replaceArgument(2, $config['paths']);
$container->getDefinition('twig.template_iterator')->replaceArgument(2, $config['paths']);
@@ -108,7 +114,7 @@ class TwigExtension extends Extension
}
}
if (is_dir($dir = $container->getParameter('kernel.root_dir').'/Resources/views')) {
if (file_exists($dir = $container->getParameter('kernel.root_dir').'/Resources/views')) {
$twigFilesystemLoaderDefinition->addMethodCall('addPath', array($dir));
}
$container->addResource(new FileExistenceResource($dir));
@@ -137,16 +143,23 @@ class TwigExtension extends Extension
$container->getDefinition('twig')->replaceArgument(1, $config);
$this->addClassesToCompile(array(
'Twig_Environment',
'Twig_Extension',
'Twig_Extension_Core',
'Twig_Extension_Escaper',
'Twig_Extension_Optimizer',
'Twig_LoaderInterface',
'Twig_Markup',
'Twig_Template',
));
$container->registerForAutoconfiguration(\Twig_ExtensionInterface::class)->addTag('twig.extension');
$container->registerForAutoconfiguration(\Twig_LoaderInterface::class)->addTag('twig.loader');
$container->registerForAutoconfiguration(ExtensionInterface::class)->addTag('twig.extension');
$container->registerForAutoconfiguration(LoaderInterface::class)->addTag('twig.loader');
if (\PHP_VERSION_ID < 70000) {
$this->addClassesToCompile(array(
'Twig_Environment',
'Twig_Extension',
'Twig_Extension_Core',
'Twig_Extension_Escaper',
'Twig_Extension_Optimizer',
'Twig_LoaderInterface',
'Twig_Markup',
'Twig_Template',
));
}
}
private function getBundleHierarchy(ContainerBuilder $container)
@@ -162,12 +175,12 @@ class TwigExtension extends Extension
);
}
if (is_dir($dir = $container->getParameter('kernel.root_dir').'/Resources/'.$name.'/views')) {
if (file_exists($dir = $container->getParameter('kernel.root_dir').'/Resources/'.$name.'/views')) {
$bundleHierarchy[$name]['paths'][] = $dir;
}
$container->addResource(new FileExistenceResource($dir));
if (is_dir($dir = $bundle['path'].'/Resources/views')) {
if (file_exists($dir = $bundle['path'].'/Resources/views')) {
$bundleHierarchy[$name]['paths'][] = $dir;
}
$container->addResource(new FileExistenceResource($dir));
+1 -1
View File
@@ -1,4 +1,4 @@
Copyright (c) 2004-2017 Fabien Potencier
Copyright (c) 2004-2018 Fabien Potencier
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
+1 -5
View File
@@ -29,11 +29,7 @@ class FilesystemLoader extends BaseFilesystemLoader
protected $parser;
/**
* Constructor.
*
* @param FileLocatorInterface $locator A FileLocatorInterface instance
* @param TemplateNameParserInterface $parser A TemplateNameParserInterface instance
* @param string|null $rootPath The root path common to all relative paths (null for getcwd())
* @param string|null $rootPath The root path common to all relative paths (null for getcwd())
*/
public function __construct(FileLocatorInterface $locator, TemplateNameParserInterface $parser, $rootPath = null)
{
+5 -3
View File
@@ -4,19 +4,21 @@
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">
<services>
<service id="twig.extension.form" class="Symfony\Bridge\Twig\Extension\FormExtension" public="false">
<defaults public="false" />
<service id="twig.extension.form" class="Symfony\Bridge\Twig\Extension\FormExtension">
<argument type="collection">
<argument type="service" id="service_container" />
<argument>twig.form.renderer</argument>
</argument>
</service>
<service id="twig.form.engine" class="Symfony\Bridge\Twig\Form\TwigRendererEngine" public="false">
<service id="twig.form.engine" class="Symfony\Bridge\Twig\Form\TwigRendererEngine">
<argument>%twig.form.resources%</argument>
<argument type="service" id="twig" />
</service>
<service id="twig.form.renderer" class="Symfony\Bridge\Twig\Form\TwigRenderer">
<service id="twig.form.renderer" class="Symfony\Bridge\Twig\Form\TwigRenderer" public="true">
<argument type="service" id="twig.form.engine" />
<argument type="service" id="security.csrf.token_manager" on-invalid="null" />
<tag name="twig.runtime" />
+5 -3
View File
@@ -4,14 +4,16 @@
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">
<services>
<service id="twig.loader.filesystem" class="Symfony\Bundle\TwigBundle\Loader\FilesystemLoader" public="false">
<defaults public="false" />
<service id="twig.loader.filesystem" class="Symfony\Bundle\TwigBundle\Loader\FilesystemLoader">
<argument type="service" id="templating.locator" />
<argument type="service" id="templating.name_parser" />
<argument /> <!-- project's root dir -->
<argument>%kernel.project_dir%</argument>
<tag name="twig.loader"/>
</service>
<service id="templating.engine.twig" class="Symfony\Bundle\TwigBundle\TwigEngine" public="false">
<service id="templating.engine.twig" class="Symfony\Bundle\TwigBundle\TwigEngine">
<argument type="service" id="twig" />
<argument type="service" id="templating.name_parser" />
<argument type="service" id="templating.locator" />
+40 -36
View File
@@ -5,7 +5,9 @@
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">
<services>
<service id="twig" class="Twig\Environment">
<defaults public="false" />
<service id="twig" class="Twig\Environment" public="true">
<argument type="service" id="twig.loader" />
<argument /> <!-- Twig options -->
<call method="addGlobal">
@@ -17,122 +19,126 @@
</call>
<configurator service="twig.configurator.environment" method="configure" />
</service>
<service id="Twig_Environment" alias="twig" />
<service id="Twig\Environment" alias="twig" />
<service id="twig.app_variable" class="Symfony\Bridge\Twig\AppVariable" public="false">
<service id="twig.app_variable" class="Symfony\Bridge\Twig\AppVariable">
<call method="setEnvironment"><argument>%kernel.environment%</argument></call>
<call method="setDebug"><argument>%kernel.debug%</argument></call>
<call method="setTokenStorage"><argument type="service" id="security.token_storage" on-invalid="ignore" /></call>
<call method="setRequestStack"><argument type="service" id="request_stack" on-invalid="ignore" /></call>
</service>
<service id="twig.cache_warmer" class="Symfony\Bundle\TwigBundle\CacheWarmer\TemplateCacheCacheWarmer" public="false">
<service id="twig.cache_warmer" class="Symfony\Bundle\TwigBundle\CacheWarmer\TemplateCacheCacheWarmer">
<tag name="kernel.cache_warmer" />
<argument type="service" id="service_container" />
<tag name="container.service_subscriber" id="twig" />
<argument type="service" id="Psr\Container\ContainerInterface" />
<argument type="service" id="templating.finder" on-invalid="ignore" />
<argument type="collection" /> <!-- Twig paths -->
</service>
<service id="twig.template_iterator" class="Symfony\Bundle\TwigBundle\TemplateIterator" public="false">
<service id="twig.template_iterator" class="Symfony\Bundle\TwigBundle\TemplateIterator">
<argument type="service" id="kernel" />
<argument>%kernel.root_dir%</argument>
<argument type="collection" /> <!-- Twig paths -->
</service>
<service id="twig.template_cache_warmer" class="Symfony\Bundle\TwigBundle\CacheWarmer\TemplateCacheWarmer" public="false">
<service id="twig.template_cache_warmer" class="Symfony\Bundle\TwigBundle\CacheWarmer\TemplateCacheWarmer">
<tag name="kernel.cache_warmer" />
<argument type="service" id="service_container" />
<argument type="service" id="twig.template_iterator" />
</service>
<service id="twig.loader.native_filesystem" class="Twig\Loader\FilesystemLoader" public="false">
<service id="twig.loader.native_filesystem" class="Twig\Loader\FilesystemLoader">
<argument type="collection" /> <!-- paths -->
<argument /> <!-- project's root dir -->
<argument>%kernel.project_dir%</argument>
<tag name="twig.loader"/>
</service>
<service id="twig.loader.chain" class="Twig\Loader\ChainLoader" public="false"/>
<service id="twig.loader.chain" class="Twig\Loader\ChainLoader" />
<service id="twig.extension.profiler" class="Symfony\Bridge\Twig\Extension\ProfilerExtension" public="false">
<service id="twig.extension.profiler" class="Symfony\Bridge\Twig\Extension\ProfilerExtension">
<argument type="service" id="twig.profile" />
<argument type="service" id="debug.stopwatch" on-invalid="null" />
</service>
<service id="twig.profile" class="Twig\Profiler\Profile" />
<service id="twig.profile" class="Twig\Profiler\Profile" public="true" />
<service id="data_collector.twig" class="Symfony\Bridge\Twig\DataCollector\TwigDataCollector" public="false">
<service id="data_collector.twig" class="Symfony\Bridge\Twig\DataCollector\TwigDataCollector">
<tag name="data_collector" template="@WebProfiler/Collector/twig.html.twig" id="twig" priority="257" />
<argument type="service" id="twig.profile" />
</service>
<service id="twig.extension.trans" class="Symfony\Bridge\Twig\Extension\TranslationExtension" public="false">
<service id="twig.extension.trans" class="Symfony\Bridge\Twig\Extension\TranslationExtension">
<argument type="service" id="translator" />
</service>
<service id="twig.extension.assets" class="Symfony\Bridge\Twig\Extension\AssetExtension" public="false">
<service id="twig.extension.assets" class="Symfony\Bridge\Twig\Extension\AssetExtension">
<argument type="service" id="assets.packages" />
</service>
<service id="twig.extension.code" class="Symfony\Bridge\Twig\Extension\CodeExtension" public="false">
<service id="twig.extension.code" class="Symfony\Bridge\Twig\Extension\CodeExtension">
<tag name="twig.extension" />
<argument type="service" id="debug.file_link_formatter" on-invalid="ignore" />
<argument>%kernel.root_dir%</argument>
<argument>%kernel.charset%</argument>
</service>
<service id="twig.extension.routing" class="Symfony\Bridge\Twig\Extension\RoutingExtension" public="false">
<service id="twig.extension.routing" class="Symfony\Bridge\Twig\Extension\RoutingExtension">
<argument type="service" id="router" />
</service>
<service id="twig.extension.yaml" class="Symfony\Bridge\Twig\Extension\YamlExtension" public="false" />
<service id="twig.extension.yaml" class="Symfony\Bridge\Twig\Extension\YamlExtension" />
<service id="twig.extension.debug.stopwatch" class="Symfony\Bridge\Twig\Extension\StopwatchExtension" public="false">
<service id="twig.extension.debug.stopwatch" class="Symfony\Bridge\Twig\Extension\StopwatchExtension">
<argument type="service" id="debug.stopwatch" on-invalid="ignore" />
<argument>%kernel.debug%</argument>
</service>
<service id="twig.extension.expression" class="Symfony\Bridge\Twig\Extension\ExpressionExtension" public="false" />
<service id="twig.extension.expression" class="Symfony\Bridge\Twig\Extension\ExpressionExtension" />
<service id="twig.extension.httpkernel" class="Symfony\Bridge\Twig\Extension\HttpKernelExtension" public="false" />
<service id="twig.extension.httpkernel" class="Symfony\Bridge\Twig\Extension\HttpKernelExtension" />
<service id="twig.runtime.httpkernel" class="Symfony\Bridge\Twig\Extension\HttpKernelRuntime">
<service id="twig.runtime.httpkernel" class="Symfony\Bridge\Twig\Extension\HttpKernelRuntime" public="true">
<argument type="service" id="fragment.handler" />
<tag name="twig.runtime" />
</service>
<service id="twig.extension.httpfoundation" class="Symfony\Bridge\Twig\Extension\HttpFoundationExtension" public="false">
<service id="twig.extension.httpfoundation" class="Symfony\Bridge\Twig\Extension\HttpFoundationExtension">
<argument type="service" id="request_stack" />
<argument type="service" id="router.request_context" on-invalid="ignore" />
</service>
<service id="twig.extension.debug" class="Twig\Extension\DebugExtension" public="false" />
<service id="twig.extension.debug" class="Twig\Extension\DebugExtension" />
<service id="workflow.twig_extension" class="Symfony\Bridge\Twig\Extension\WorkflowExtension">
<argument type="service" id="workflow.registry" />
</service>
<service id="twig.translation.extractor" class="Symfony\Bridge\Twig\Translation\TwigExtractor">
<service id="twig.translation.extractor" class="Symfony\Bridge\Twig\Translation\TwigExtractor" public="true">
<argument type="service" id="twig" />
<tag name="translation.extractor" alias="twig" />
</service>
<service id="twig.exception_listener" class="Symfony\Component\HttpKernel\EventListener\ExceptionListener">
<service id="workflow.twig_extension" class="Symfony\Bridge\Twig\Extension\WorkflowExtension" public="true">
<argument type="service" id="workflow.registry" />
</service>
<service id="twig.exception_listener" class="Symfony\Component\HttpKernel\EventListener\ExceptionListener" public="true">
<tag name="kernel.event_subscriber" />
<tag name="monolog.logger" channel="request" />
<argument>%twig.exception_listener.controller%</argument>
<argument type="service" id="logger" on-invalid="null" />
<argument>%kernel.debug%</argument>
</service>
<service id="twig.controller.exception" class="Symfony\Bundle\TwigBundle\Controller\ExceptionController">
<service id="twig.controller.exception" class="Symfony\Bundle\TwigBundle\Controller\ExceptionController" public="true">
<argument type="service" id="twig" />
<argument>%kernel.debug%</argument>
</service>
<service id="twig.controller.preview_error" class="Symfony\Bundle\TwigBundle\Controller\PreviewErrorController">
<service id="twig.controller.preview_error" class="Symfony\Bundle\TwigBundle\Controller\PreviewErrorController" public="true">
<argument type="service" id="http_kernel" />
<argument>%twig.exception_listener.controller%</argument>
</service>
<service id="twig.configurator.environment" class="Symfony\Bundle\TwigBundle\DependencyInjection\Configurator\EnvironmentConfigurator" public="false">
<service id="twig.configurator.environment" class="Symfony\Bundle\TwigBundle\DependencyInjection\Configurator\EnvironmentConfigurator">
<argument /> <!-- date format, set in TwigExtension -->
<argument /> <!-- interval format, set in TwigExtension -->
<argument /> <!-- timezone, set in TwigExtension -->
@@ -141,10 +147,8 @@
<argument /> <!-- thousands separator, set in TwigExtension -->
</service>
<service id="twig.runtime_loader" class="Symfony\Bundle\TwigBundle\ContainerAwareRuntimeLoader" public="false">
<argument type="service" id="service_container" />
<argument type="collection" /> <!-- the mapping between class names and service names -->
<argument type="service" id="logger" on-invalid="null" />
<service id="twig.runtime_loader" class="Twig\RuntimeLoader\ContainerRuntimeLoader">
<argument /> <!-- runtime locator -->
</service>
</services>
</container>
@@ -1 +1 @@
{% include '@Twig/Exception/error.xml.twig' %}
{{ include('@Twig/Exception/error.xml.twig') }}
@@ -1 +1 @@
{% include '@Twig/Exception/error.xml.twig' %}
{{ include('@Twig/Exception/error.xml.twig') }}
@@ -1 +1 @@
{% include '@Twig/Exception/exception.xml.twig' with { 'exception': exception } %}
{{ include('@Twig/Exception/exception.xml.twig', { exception: exception }) }}
@@ -1,3 +1,3 @@
/*
{% include '@Twig/Exception/exception.txt.twig' with { 'exception': exception } %}
{{ include('@Twig/Exception/exception.txt.twig', { exception: exception }) }}
*/
@@ -1,120 +1,102 @@
<div class="block-exception">
<div class="block-exception-detected clear-fix">
<div class="support">
<a href="http://symfony.com/support">Need support?</a>
<div class="exception-summary {{ exception.message is empty ? 'exception-without-message' }}">
<div class="exception-metadata">
<div class="container">
<h2 class="exception-hierarchy">
{% for previousException in exception.allPrevious|reverse %}
{{ previousException.class|abbr_class }}
<span class="icon">{{ include('@Twig/images/chevron-right.svg') }}</span>
{% endfor %}
{{ exception.class|abbr_class }}
</h2>
<h2 class="exception-http">
HTTP {{ status_code }} <small>{{ status_text }}</small>
</h2>
</div>
<div class="illustration-exception">
{{ include('@Twig/Exception/exception.svg') }}
</div>
<div class="text-exception">
<div class="open-quote">“</div>
</div>
<h1>{{ exception.message|nl2br|format_file_from_text }}</h1>
<div class="exception-message-wrapper">
<div class="container">
<h1 class="break-long-words exception-message {{ exception.message|length > 180 ? 'long' }}">
{{- exception.message|nl2br|format_file_from_text -}}
</h1>
<div>
<strong>{{ status_code }}</strong> {{ status_text }} - {{ exception.class|abbr_class }}
<div class="exception-illustration hidden-xs-down">
{{ include('@Twig/images/symfony-ghost.svg') }}
</div>
{% set previous_count = exception.allPrevious|length %}
{% if previous_count %}
<div class="linked"><span><strong>{{ previous_count }}</strong> linked Exception{{ previous_count > 1 ? 's' : '' }}:</span>
<ul>
{% for i, previous in exception.allPrevious %}
<li>
{{ previous.class|abbr_class }} <a href="#traces-link-{{ i + 1 }}" onclick="toggle('traces-{{ i + 1 }}', 'traces'); switchIcons('icon-traces-{{ i + 1 }}-open', 'icon-traces-{{ i + 1 }}-close');">&#187;</a>
</li>
{% endfor %}
</ul>
</div>
{% endif %}
<div class="close-quote">”</div>
</div>
</div>
</div>
{% for position, e in exception.toarray %}
{% include '@Twig/Exception/traces.html.twig' with { 'exception': e, 'position': position, 'count': previous_count } only %}
{% endfor %}
<div class="container">
<div class="sf-tabs">
<div class="tab">
{% set exception_as_array = exception.toarray %}
{% set _exceptions_with_user_code = [] %}
{% for i, e in exception_as_array %}
{% for trace in e.trace %}
{% if (trace.file is not empty) and ('/vendor/' not in trace.file) and ('/var/cache/' not in trace.file) and not loop.last %}
{% set _exceptions_with_user_code = _exceptions_with_user_code|merge([i]) %}
{% endif %}
{% endfor %}
{% endfor %}
<h3 class="tab-title">
{% if exception_as_array|length > 1 %}
Exceptions <span class="badge">{{ exception_as_array|length }}</span>
{% else %}
Exception
{% endif %}
</h3>
{% if logger %}
<div class="block">
<div class="logs clear-fix">
{% spaceless %}
<h2>
Logs&nbsp;
<a href="#" onclick="toggle('logs'); switchIcons('icon-logs-open', 'icon-logs-close'); return false;">
<img class="toggle" id="icon-logs-open" alt="+" src="data:image/gif;base64,R0lGODlhEgASAMQTANft99/v+Ga44bHb8ITG52S44dXs9+z1+uPx+YvK6WC24G+944/M6W28443L6dnu+Ge54v/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABMALAAAAAASABIAQAVS4DQBTiOd6LkwgJgeUSzHSDoNaZ4PU6FLgYBA5/vFID/DbylRGiNIZu74I0h1hNsVxbNuUV4d9SsZM2EzWe1qThVzwWFOAFCQFa1RQq6DJB4iIQA7" style="display: none" />
<img class="toggle" id="icon-logs-close" alt="-" src="data:image/gif;base64,R0lGODlhEgASAMQSANft94TG57Hb8GS44ez1+mC24IvK6ePx+Wa44dXs92+942e54o3L6W2844/M6dnu+P/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABIALAAAAAASABIAQAVCoCQBTBOd6Kk4gJhGBCTPxysJb44K0qD/ER/wlxjmisZkMqBEBW5NHrMZmVKvv9hMVsO+hE0EoNAstEYGxG9heIhCADs=" style="display: inline" />
</a>
</h2>
{% endspaceless %}
{% if logger.counterrors %}
<div class="error-count">
<span>
{{ logger.counterrors }} error{{ logger.counterrors > 1 ? 's' : ''}}
</span>
</div>
{% endif %}
<div class="tab-content">
{% for i, e in exception_as_array %}
{{ include('@Twig/Exception/traces.html.twig', { exception: e, index: loop.index, expand: i in _exceptions_with_user_code or (_exceptions_with_user_code is empty and loop.first) }, with_context = false) }}
{% endfor %}
</div>
</div>
<div id="logs">
{% include '@Twig/Exception/logs.html.twig' with { 'logs': logger.logs } only %}
{% if logger %}
<div class="tab {{ logger.logs is empty ? 'disabled' }}">
<h3 class="tab-title">
Logs
{% if logger.counterrors ?? false %}<span class="badge status-error">{{ logger.counterrors }}</span>{% endif %}
</h3>
<div class="tab-content">
{% if logger.logs %}
{{ include('@Twig/Exception/logs.html.twig', { logs: logger.logs }, with_context = false) }}
{% else %}
<div class="empty">
<p>No log messages</p>
</div>
{% endif %}
</div>
</div>
{% endif %}
<div class="tab">
<h3 class="tab-title">
{% if exception_as_array|length > 1 %}
Stack Traces <span class="badge">{{ exception_as_array|length }}</span>
{% else %}
Stack Trace
{% endif %}
</h3>
<div class="tab-content">
{% for e in exception_as_array %}
{{ include('@Twig/Exception/traces_text.html.twig', { exception: e, index: loop.index, num_exceptions: loop.length }, with_context = false) }}
{% endfor %}
</div>
</div>
{% if currentContent is not empty %}
<div class="tab">
<h3 class="tab-title">Output content</h3>
<div class="tab-content">
{{ currentContent }}
</div>
</div>
{% endif %}
</div>
{% endif %}
{% if currentContent %}
<div class="block">
{% spaceless %}
<h2>
Content of the Output&nbsp;
<a href="#" onclick="toggle('output-content'); switchIcons('icon-content-open', 'icon-content-close'); return false;">
<img class="toggle" id="icon-content-close" alt="-" src="data:image/gif;base64,R0lGODlhEgASAMQSANft94TG57Hb8GS44ez1+mC24IvK6ePx+Wa44dXs92+942e54o3L6W2844/M6dnu+P/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABIALAAAAAASABIAQAVCoCQBTBOd6Kk4gJhGBCTPxysJb44K0qD/ER/wlxjmisZkMqBEBW5NHrMZmVKvv9hMVsO+hE0EoNAstEYGxG9heIhCADs=" style="display: none" />
<img class="toggle" id="icon-content-open" alt="+" src="data:image/gif;base64,R0lGODlhEgASAMQTANft99/v+Ga44bHb8ITG52S44dXs9+z1+uPx+YvK6WC24G+944/M6W28443L6dnu+Ge54v/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABMALAAAAAASABIAQAVS4DQBTiOd6LkwgJgeUSzHSDoNaZ4PU6FLgYBA5/vFID/DbylRGiNIZu74I0h1hNsVxbNuUV4d9SsZM2EzWe1qThVzwWFOAFCQFa1RQq6DJB4iIQA7" style="display: inline" />
</a>
</h2>
{% endspaceless %}
<div id="output-content" style="display: none">
{{ currentContent }}
</div>
<div style="clear: both"></div>
</div>
{% endif %}
{% include '@Twig/Exception/traces_text.html.twig' with { 'exception': exception } only %}
<script type="text/javascript">//<![CDATA[
function toggle(id, clazz) {
var el = document.getElementById(id),
current = el.style.display,
i;
if (clazz) {
var tags = document.getElementsByTagName('*');
for (i = tags.length - 1; i >= 0; i--) {
if (tags[i].className === clazz) {
tags[i].style.display = 'none';
}
}
}
el.style.display = current === 'none' ? 'block' : 'none';
}
function switchIcons(id1, id2) {
var icon1, icon2, display1, display2;
icon1 = document.getElementById(id1);
icon2 = document.getElementById(id2);
display1 = icon1.style.display;
display2 = icon2.style.display;
icon1.style.display = display2;
icon2.style.display = display1;
}
//]]></script>
</div>
@@ -1,3 +1,3 @@
/*
{% include '@Twig/Exception/exception.txt.twig' with { 'exception': exception } %}
{{ include('@Twig/Exception/exception.txt.twig', { exception: exception }) }}
*/
@@ -1 +1 @@
{% include '@Twig/Exception/exception.xml.twig' with { 'exception': exception } %}
{{ include('@Twig/Exception/exception.xml.twig', { exception: exception }) }}
File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 8.0 KiB

@@ -2,6 +2,6 @@
[message] {{ exception.message }}
{% for i, e in exception.toarray %}
[{{ i + 1 }}] {{ e.class }}: {{ e.message }}
{% include '@Twig/Exception/traces.txt.twig' with { 'exception': e } only %}
{{ include('@Twig/Exception/traces.txt.twig', { exception: e }, with_context = false) }}
{% endfor %}
@@ -3,7 +3,7 @@
<error code="{{ status_code }}" message="{{ status_text }}">
{% for e in exception.toarray %}
<exception class="{{ e.class }}" message="{{ e.message }}">
{% include '@Twig/Exception/traces.xml.twig' with { 'exception': e } only %}
{{ include('@Twig/Exception/traces.xml.twig', { exception: e }, with_context = false) }}
</exception>
{% endfor %}
</error>
@@ -1,7 +1,36 @@
<ol class="traces logs">
{% set channel_is_defined = (logs|first).channel is defined %}
<table class="logs">
<thead>
<tr>
<th>Level</th>
{% if channel_is_defined %}<th>Channel</th>{% endif %}
<th class="full-width">Message</th>
</tr>
</thead>
<tbody>
{% for log in logs %}
<li{% if log.priority >= 400 %} class="error"{% elseif log.priority >= 300 %} class="warning"{% endif %}>
{{ log.priorityName }} - {{ log.message|format_log_message(log.context) }}
</li>
{% if log.priority >= 400 %}
{% set status = 'error' %}
{% elseif log.priority >= 300 %}
{% set status = 'warning' %}
{% else %}
{% set severity = log.context.exception.severity|default(false) %}
{% set status = severity is constant('E_DEPRECATED') or severity is constant('E_USER_DEPRECATED') ? 'warning' : 'normal' %}
{% endif %}
<tr class="status-{{ status }}">
<td class="text-small" nowrap>
<span class="colored text-bold">{{ log.priorityName }}</span>
<span class="text-muted newline">{{ log.timestamp|date('H:i:s') }}</span>
</td>
{% if channel_is_defined %}
<td class="text-small text-bold nowrap">
{{ log.channel }}
</td>
{% endif %}
<td>{{ log.message|format_log_message(log.context) }}</td>
</tr>
{% endfor %}
</ol>
</tbody>
</table>
@@ -1,22 +1,33 @@
{% if trace.function %}
at
<strong>
<abbr title="{{ trace.class }}">{{ trace.short_class }}</abbr>
{{ trace.type ~ trace.function }}
</strong>
({{ trace.args|format_args }})
{% endif %}
<div class="trace-line-header break-long-words {{ trace.file|default(false) ? 'sf-toggle' }}" data-toggle-selector="#trace-html-{{ prefix }}-{{ i }}" data-toggle-initial="{{ _display_code_snippet ? 'display' }}">
{% if trace.file|default(false) %}
<span class="icon icon-close">{{ include('@Twig/images/icon-minus-square.svg') }}</span>
<span class="icon icon-open">{{ include('@Twig/images/icon-plus-square.svg') }}</span>
{% endif %}
{% if trace.file is defined and trace.file and trace.line is defined and trace.line %}
{{ trace.function ? '<br />' : '' }}
in {{ trace.file|format_file(trace.line) }}&nbsp;
{% spaceless %}
<a href="#" onclick="toggle('trace-{{ prefix ~ '-' ~ i }}'); switchIcons('icon-{{ prefix ~ '-' ~ i }}-open', 'icon-{{ prefix ~ '-' ~ i }}-close'); return false;">
<img class="toggle" id="icon-{{ prefix ~ '-' ~ i }}-close" alt="-" src="data:image/gif;base64,R0lGODlhEgASAMQSANft94TG57Hb8GS44ez1+mC24IvK6ePx+Wa44dXs92+942e54o3L6W2844/M6dnu+P/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABIALAAAAAASABIAQAVCoCQBTBOd6Kk4gJhGBCTPxysJb44K0qD/ER/wlxjmisZkMqBEBW5NHrMZmVKvv9hMVsO+hE0EoNAstEYGxG9heIhCADs=" style="display: {{ 0 == i ? 'inline' : 'none' }}" />
<img class="toggle" id="icon-{{ prefix ~ '-' ~ i }}-open" alt="+" src="data:image/gif;base64,R0lGODlhEgASAMQTANft99/v+Ga44bHb8ITG52S44dXs9+z1+uPx+YvK6WC24G+944/M6W28443L6dnu+Ge54v/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABMALAAAAAASABIAQAVS4DQBTiOd6LkwgJgeUSzHSDoNaZ4PU6FLgYBA5/vFID/DbylRGiNIZu74I0h1hNsVxbNuUV4d9SsZM2EzWe1qThVzwWFOAFCQFa1RQq6DJB4iIQA7" style="display: {{ 0 == i ? 'none' : 'inline' }}" />
</a>
{% endspaceless %}
<div id="trace-{{ prefix ~ '-' ~ i }}" style="display: {{ 0 == i ? 'block' : 'none' }}" class="trace">
{{ trace.file|file_excerpt(trace.line) }}
{% if trace.function %}
<span class="trace-class">{{ trace.class|abbr_class }}</span>{% if trace.type is not empty %}<span class="trace-type">{{ trace.type }}</span>{% endif %}<span class="trace-method">{{ trace.function }}</span><span class="trace-arguments">({{ trace.args|format_args }})</span>
{% endif %}
{% if trace.file|default(false) %}
{% set line_number = trace.line|default(1) %}
{% set file_link = trace.file|file_link(line_number) %}
{% set file_path = trace.file|format_file(line_number)|striptags|replace({ (' at line ' ~ line_number): '' }) %}
{% set file_path_parts = file_path|split(constant('DIRECTORY_SEPARATOR')) %}
<span class="block trace-file-path">
in
<a href="{{ file_link }}">{{ file_path_parts[:-1]|join(constant('DIRECTORY_SEPARATOR')) }}{{ constant('DIRECTORY_SEPARATOR') }}<strong>{{ file_path_parts|last }}</strong></a>
(line {{ line_number }})
</span>
{% endif %}
</div>
{% if trace.file|default(false) %}
<div id="trace-html-{{ prefix ~ '-' ~ i }}" class="trace-code sf-toggle-content">
{{ trace.file|file_excerpt(trace.line, 5)|replace({
'#DD0000': '#183691',
'#007700': '#a71d5d',
'#0000BB': '#222222',
'#FF8000': '#969896'
})|raw }}
</div>
{% endif %}
@@ -1,8 +1,6 @@
{% if trace.function %}
at {{ trace.class ~ trace.type ~ trace.function }}({{ trace.args|format_args_as_text }})
{% else %}
at n/a
{% endif %}
{% if trace.file is defined and trace.line is defined %}
in {{ trace.file }} line {{ trace.line }}
{% endif %}
at {{ trace.class ~ trace.type ~ trace.function }}({{ trace.args|format_args }})
{%- endif -%}
{% if trace.file|default('') is not empty and trace.line|default('') is not empty %}
{{- trace.function ? '\n (' : 'at '}}{{ trace.file|format_file(trace.line)|striptags|replace({ (' at line ' ~ trace.line): '' }) }}:{{ trace.line }}{{ trace.function ? ')' }}
{%- endif %}
@@ -1,25 +1,33 @@
<div class="block">
{% if count > 0 %}
<h2>
<span><small>[{{ count - position + 1 }}/{{ count + 1 }}]</small></span>
{{ exception.class|abbr_class }}: {{ exception.message|nl2br|format_file_from_text }}&nbsp;
{% spaceless %}
<a href="#" onclick="toggle('traces-{{ position }}', 'traces'); switchIcons('icon-traces-{{ position }}-open', 'icon-traces-{{ position }}-close'); return false;">
<img class="toggle" id="icon-traces-{{ position }}-close" alt="-" src="data:image/gif;base64,R0lGODlhEgASAMQSANft94TG57Hb8GS44ez1+mC24IvK6ePx+Wa44dXs92+942e54o3L6W2844/M6dnu+P/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABIALAAAAAASABIAQAVCoCQBTBOd6Kk4gJhGBCTPxysJb44K0qD/ER/wlxjmisZkMqBEBW5NHrMZmVKvv9hMVsO+hE0EoNAstEYGxG9heIhCADs=" style="display: {{ 0 == count ? 'inline' : 'none' }}" />
<img class="toggle" id="icon-traces-{{ position }}-open" alt="+" src="data:image/gif;base64,R0lGODlhEgASAMQTANft99/v+Ga44bHb8ITG52S44dXs9+z1+uPx+YvK6WC24G+944/M6W28443L6dnu+Ge54v/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABMALAAAAAASABIAQAVS4DQBTiOd6LkwgJgeUSzHSDoNaZ4PU6FLgYBA5/vFID/DbylRGiNIZu74I0h1hNsVxbNuUV4d9SsZM2EzWe1qThVzwWFOAFCQFa1RQq6DJB4iIQA7" style="display: {{ 0 == count ? 'none' : 'inline' }}" />
</a>
{% endspaceless %}
</h2>
{% else %}
<h2>Stack Trace</h2>
{% endif %}
<div class="trace trace-as-html">
<div class="trace-details">
<div class="trace-head">
<span class="sf-toggle" data-toggle-selector="#trace-html-{{ index }}" data-toggle-initial="{{ expand ? 'display' }}">
<h3 class="trace-class">
<span class="trace-namespace">
{{ exception.class|split('\\')|slice(0, -1)|join('\\') }}
{{- exception.class|split('\\')|length > 1 ? '\\' }}
</span>
{{ exception.class|split('\\')|last }}
<a id="traces-link-{{ position }}"></a>
<ol class="traces list-exception" id="traces-{{ position }}" style="display: {{ 0 == count ? 'block' : 'none' }}">
<span class="icon icon-close">{{ include('@Twig/images/icon-minus-square-o.svg') }}</span>
<span class="icon icon-open">{{ include('@Twig/images/icon-plus-square-o.svg') }}</span>
</h3>
{% if exception.message is not empty and index > 1 %}
<p class="break-long-words trace-message">{{ exception.message }}</p>
{% endif %}
</span>
</div>
<div id="trace-html-{{ index }}" class="sf-toggle-content">
{% set _is_first_user_code = true %}
{% for i, trace in exception.trace %}
<li>
{% include '@Twig/Exception/trace.html.twig' with { 'prefix': position, 'i': i, 'trace': trace } only %}
</li>
{% set _display_code_snippet = _is_first_user_code and ('/vendor/' not in trace.file) and ('/var/cache/' not in trace.file) and (trace.file is not empty) %}
{% if _display_code_snippet %}{% set _is_first_user_code = false %}{% endif %}
<div class="trace-line">
{{ include('@Twig/Exception/trace.html.twig', { prefix: index, i: i, trace: trace, _display_code_snippet: _display_code_snippet }, with_context = false) }}
</div>
{% endfor %}
</ol>
</div>
</div>
</div>
@@ -1,6 +1,12 @@
{% if exception.trace|length %}
{% for trace in exception.trace %}
{% include '@Twig/Exception/trace.txt.twig' with { 'trace': trace } only %}
{% endfor %}
<pre class="stacktrace">
{{ exception.class }}:
{% if exception.message is not empty %}
{{- exception.message }}
{% endif %}
{% for trace in exception.trace %}
{{ include('@Twig/Exception/trace.txt.twig', { trace: trace }, with_context = false) }}
{% endfor %}
</pre>
{% endif %}
@@ -1,7 +1,7 @@
<traces>
{% for trace in exception.trace %}
<trace>
{% include '@Twig/Exception/trace.txt.twig' with { 'trace': trace } only %}
{{ include('@Twig/Exception/trace.txt.twig', { trace: trace }, with_context = false) }}
</trace>
{% endfor %}
@@ -1,18 +1,24 @@
<div class="block">
<h2>
Stack Trace (Plain Text)&nbsp;
{% spaceless %}
<a href="#" onclick="toggle('traces-text'); switchIcons('icon-traces-text-open', 'icon-traces-text-close'); return false;">
<img class="toggle" id="icon-traces-text-close" alt="-" src="data:image/gif;base64,R0lGODlhEgASAMQSANft94TG57Hb8GS44ez1+mC24IvK6ePx+Wa44dXs92+942e54o3L6W2844/M6dnu+P/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABIALAAAAAASABIAQAVCoCQBTBOd6Kk4gJhGBCTPxysJb44K0qD/ER/wlxjmisZkMqBEBW5NHrMZmVKvv9hMVsO+hE0EoNAstEYGxG9heIhCADs=" style="display: none" />
<img class="toggle" id="icon-traces-text-open" alt="+" src="data:image/gif;base64,R0lGODlhEgASAMQTANft99/v+Ga44bHb8ITG52S44dXs9+z1+uPx+YvK6WC24G+944/M6W28443L6dnu+Ge54v/+/l614P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAABMALAAAAAASABIAQAVS4DQBTiOd6LkwgJgeUSzHSDoNaZ4PU6FLgYBA5/vFID/DbylRGiNIZu74I0h1hNsVxbNuUV4d9SsZM2EzWe1qThVzwWFOAFCQFa1RQq6DJB4iIQA7" style="display: inline" />
</a>
{% endspaceless %}
</h2>
<table class="trace trace-as-text">
<thead class="trace-head">
<tr>
<th class="sf-toggle" data-toggle-selector="#trace-text-{{ index }}" data-toggle-initial="{{ 1 == index ? 'display' }}">
<h3 class="trace-class">
{% if num_exceptions > 1 %}
<span class="text-muted">[{{ num_exceptions - index + 1 }}/{{ num_exceptions }}]</span>
{% endif %}
{{ exception.class|split('\\')|last }}
<span class="icon icon-close">{{ include('@Twig/images/icon-minus-square-o.svg') }}</span>
<span class="icon icon-open">{{ include('@Twig/images/icon-plus-square-o.svg') }}</span>
</h3>
</th>
</tr>
</thead>
<div id="traces-text" class="trace" style="display: none;">
<pre>{% for i, e in exception.toarray %}
[{{ i + 1 }}] {{ e.class }}: {{ e.message }}
{% include '@Twig/Exception/traces.txt.twig' with { 'exception': e } only %}
{% endfor %}</pre>
</div>
</div>
<tbody id="trace-text-{{ index }}">
<tr>
<td>
{{ include('@Twig/Exception/traces.txt.twig', { exception: exception }, with_context = false) }}
</td>
</tr>
</tbody>
</table>
+20 -235
View File
@@ -3,249 +3,34 @@
<head>
<meta charset="{{ _charset }}" />
<meta name="robots" content="noindex,nofollow" />
<meta name="viewport" content="width=device-width,initial-scale=1" />
<title>{% block title %}{% endblock %}</title>
<style>
html {
background: #eee;
}
body {
font: 11px Verdana, Arial, sans-serif;
color: #333;
}
.sf-reset, .sf-reset .block, .sf-reset #message {
margin: auto;
}
img {
border: 0;
}
.clear {
clear: both;
height: 0;
font-size: 0;
line-height: 0;
}
.clear-fix:after {
content: "\0020";
display: block;
height: 0;
clear: both;
visibility: hidden;
}
.clear-fix {
display: inline-block;
}
* html .clear-fix {
height: 1%;
}
.clear-fix {
display: block;
}
.header {
padding: 30px 30px 20px 30px;
}
.header-logo {
float: left;
}
.search {
float: right;
padding-top: 20px;
}
.search label {
line-height: 28px;
vertical-align: middle;
}
.search input {
width: 195px;
font-size: 12px;
border: 1px solid #dadada;
background: #fff url(data:image/gif;base64,R0lGODlhAQAFAKIAAPX19e/v7/39/fr6+urq6gAAAAAAAAAAACH5BAAAAAAALAAAAAABAAUAAAMESAEjCQA7) repeat-x left top;
padding: 5px 6px;
color: #565656;
}
.search input[type="search"] {
-webkit-appearance: textfield;
}
#content {
width: 970px;
margin: 0 auto;
}
#content pre {
white-space: normal;
font-family: Arial, Helvetica, sans-serif;
}
/*
Copyright (c) 2010, Yahoo! Inc. All rights reserved.
Code licensed under the BSD License:
http://developer.yahoo.com/yui/license.html
version: 3.1.2
build: 56
*/
.sf-reset div,.sf-reset dl,.sf-reset dt,.sf-reset dd,.sf-reset ul,.sf-reset ol,.sf-reset li,.sf-reset h1,.sf-reset h2,.sf-reset h3,.sf-reset h4,.sf-reset h5,.sf-reset h6,.sf-reset pre,.sf-reset code,.sf-reset form,.sf-reset fieldset,.sf-reset legend,.sf-reset input,.sf-reset textarea,.sf-reset p,.sf-reset blockquote,.sf-reset th,.sf-reset td{margin:0;padding:0;}.sf-reset table{border-collapse:collapse;border-spacing:0;}.sf-reset fieldset,.sf-reset img{border:0;}.sf-reset address,.sf-reset caption,.sf-reset cite,.sf-reset code,.sf-reset dfn,.sf-reset em,.sf-reset strong,.sf-reset th,.sf-reset var{font-style:normal;font-weight:normal;}.sf-reset li{list-style:none;}.sf-reset caption,.sf-reset th{text-align:left;}.sf-reset h1,.sf-reset h2,.sf-reset h3,.sf-reset h4,.sf-reset h5,.sf-reset h6{font-size:100%;font-weight:normal;}.sf-reset q:before,.sf-reset q:after{content:'';}.sf-reset abbr,.sf-reset acronym{border:0;font-variant:normal;}.sf-reset sup{vertical-align:text-top;}.sf-reset sub{vertical-align:text-bottom;}.sf-reset input,.sf-reset textarea,.sf-reset select{font-family:inherit;font-size:inherit;font-weight:inherit;}.sf-reset input,.sf-reset textarea,.sf-reset select{font-size:100%;}.sf-reset legend{color:#000;}
.sf-reset abbr {
border-bottom: 1px dotted #000;
cursor: help;
}
.sf-reset p {
font-size: 14px;
line-height: 20px;
padding-bottom: 20px;
}
.sf-reset strong {
color: #313131;
font-weight: bold;
}
.sf-reset a {
color: #6c6159;
}
.sf-reset a img {
border: none;
}
.sf-reset a:hover {
text-decoration: underline;
}
.sf-reset em {
font-style: italic;
}
.sf-reset h2,
.sf-reset h3 {
font-weight: bold;
}
.sf-reset h1 {
font-family: Georgia, "Times New Roman", Times, serif;
font-size: 20px;
color: #313131;
word-wrap: break-word;
}
.sf-reset li {
padding-bottom: 10px;
}
.sf-reset .block {
-moz-border-radius: 16px;
-webkit-border-radius: 16px;
border-radius: 16px;
margin-bottom: 20px;
background-color: #FFFFFF;
border: 1px solid #dfdfdf;
padding: 40px 50px;
word-break: break-all;
}
.sf-reset h2 {
font-size: 16px;
font-family: Arial, Helvetica, sans-serif;
}
.sf-reset li a {
background: none;
color: #868686;
text-decoration: none;
}
.sf-reset li a:hover {
background: none;
color: #313131;
text-decoration: underline;
}
.sf-reset ol {
padding: 10px 0;
}
.sf-reset ol li {
list-style: decimal;
margin-left: 20px;
padding: 2px;
padding-bottom: 20px;
}
.sf-reset ol ol li {
list-style-position: inside;
margin-left: 0;
white-space: nowrap;
font-size: 12px;
padding-bottom: 0;
}
.sf-reset li .selected {
background-color: #ffd;
}
.sf-button {
display: -moz-inline-box;
display: inline-block;
text-align: center;
vertical-align: middle;
border: 0;
background: transparent none;
text-transform: uppercase;
cursor: pointer;
font: bold 11px Arial, Helvetica, sans-serif;
}
.sf-button span {
text-decoration: none;
display: block;
height: 28px;
float: left;
}
.sf-button .border-l {
text-decoration: none;
display: block;
height: 28px;
float: left;
padding: 0 0 0 7px;
background: transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAcCAYAAACtQ6WLAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAQtJREFUeNpiPHnyJAMakARiByDWYEGT8ADiYGVlZStubm5xlv///4MEQYoKZGRkQkRERLRYWVl5wYJQyXBZWdkwCQkJUxAHKgaWlAHSLqKiosb//v1DsYMFKGCvoqJiDmQzwXTAJYECulxcXNLoumCSoszMzDzoumDGghQwYZUECWIzkrAkSIIGOmlkLI10AiX//P379x8jIyMTNmPf/v79+ysLCwsvuiQoNi5//fr1Kch4dAyS3P/gwYMTQBP+wxwHw0xA4gkQ73v9+vUZdJ2w1Lf82bNn4iCHCQoKasHsZw4ODgbRIL8c+/Lly5M3b978Y2dn5wC6npkFLXnsAOKLjx49AmUHLYAAAwBoQubG016R5wAAAABJRU5ErkJggg==) no-repeat top left;
}
.sf-button .border-r {
padding: 0 7px 0 0;
background: transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAcCAYAAACtQ6WLAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAR1JREFUeNpiPHnyZCMDA8MNID5gZmb2nAEJMH7//v3N169fX969e/cYkL8WqGAHXPLv37//QYzfv39/fvPmzbUnT56sAXInmJub/2H5/x8sx8DCwsIrISFhDmQyPX78+CmQXs70798/BmQsKipqBNTgdvz4cWkmkE5kDATMioqKZkCFdiwg1eiAi4tLGqhQF24nMmBmZuYEigth1QkEbEBxTlySYPvJkwSJ00AnjYylgU6gxB8g/oFVEphkvgLF32KNMmCCewYUv4qhEyj47+HDhyeBzIMYOoEp8CxQw56wsLAncJ1//vz5/P79+2svX74EJc2V4BT58+fPd8CE/QKYHMGJOiIiAp6oWW7evDkNSF8DZYfIyEiU7AAQYACJ2vxVdJW4eQAAAABJRU5ErkJggg==) right top no-repeat;
}
.sf-button .btn-bg {
padding: 0 14px;
color: #636363;
line-height: 28px;
background: transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAcCAYAAACgXdXMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAClJREFUeNpiPnny5EKGf//+/Wf6//8/A4QAcrGzKCZwGc9sa2urBBBgAIbDUoYVp9lmAAAAAElFTkSuQmCC) repeat-x top left;
}
.sf-button:hover .border-l,
.sf-button-selected .border-l {
background: transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAcCAYAAACtQ6WLAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAR9JREFUeNpi/P//PwMyOHfunDqQSgNiexZkibNnzxYBqZa3HOs5v7PcYQBLnjlzhg1IbfzIdsTjA/t+ht9Mr8GKwZL//v3r+sB+0OMN+zqIEf8gFMvJkyd1gXTOa9YNDP//otrPAtSV/Jp9HfPff78Z0AEL0LUeXxivMfxD0wXTqfjj/2ugkf+wSrL9/YtpJEyS4S8WI5Ek/+GR/POPFjr//cenE6/kP9q4Fo/kr39/mdj+M/zFkGQCSj5i+ccPjLJ/GBgkuYOHQR1sNDpmAkb2LBmWwL///zKCIxwZM0VHR18G6p4uxeLLAA4tJMwEshiou1iMxXaHLGswA+t/YbhORuQUv2DBAnCifvxzI+enP3dQJUFg/vz5sOzgBBBgAPxX9j0YnH4JAAAAAElFTkSuQmCC) no-repeat top left;
}
.sf-button:hover .border-r,
.sf-button-selected .border-r {
background: transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAcCAYAAACtQ6WLAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAT5JREFUeNpiPHv27BkGBoaDQDzLyMjoJgMSYHrM3WX8hn1d0f///88DFRYhSzIuv2X5H8Rg/SfKIPDTkYH/l80OINffxMTkF9O/f/8ZQPgnwyuGl+wrGd6x7vf49+9fO9jYf3+Bkkj4NesmBqAV+SdPntQC6vzHgIz//gOawbqOGchOxtAJwp8Zr4F0e7D8/fuPAR38/P8eZIo0yz8skv8YvoIk+YE6/zNgAyD7sRqLkPzzjxY6/+HS+R+fTkZ8djLh08lCUCcuSWawJGbwMTGwg7zyBatX2Bj5QZKPsBrLzaICktzN8g/NWEYGZgYZjoC/wMiei5FMpFh8QPSU6Ojoy3Cd7EwiDBJsDgxiLNY7gLrKQGIsHAxSDHxAO2TZ/b8D+TVxcXF9MCtYtLiKLgDpfUDVsxITE1GyA0CAAQA2E/N8VuHyAAAAAABJRU5ErkJggg==) right top no-repeat;
}
.sf-button:hover .btn-bg,
.sf-button-selected .btn-bg {
color: #FFFFFF;
text-shadow:0 1px 1px #6b9311;
background: transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAcCAIAAAAvP0KbAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAEFJREFUeNpiPnv2LNMdvlymf///M/37B8R/QfQ/MP33L4j+B6Qh7L9//sHpf2h8MA1V+w/KRjYLaDaLCU8vQIABAFO3TxZriO4yAAAAAElFTkSuQmCC) repeat-x top left;
}
</style>
<link rel="icon" type="image/png" href="{{ include('@Twig/images/favicon.png.base64') }}">
<style>{{ include('@Twig/exception.css.twig') }}</style>
{% block head %}{% endblock %}
</head>
<body>
<div id="content">
<div class="header clear-fix">
<div class="header-logo">
{{ include('@Twig/symfony.svg') }}
<header>
<div class="container">
<h1 class="logo">{{ include('@Twig/images/symfony-logo.svg') }} Symfony Exception</h1>
<div class="help-link">
<a href="https://symfony.com/doc">
<span class="icon">{{ include('@Twig/images/icon-book.svg') }}</span>
<span class="hidden-xs-down">Symfony</span> Docs
</a>
</div>
<div class="search">
<form method="get" action="https://symfony.com/search" target="_blank">
<div class="form-row">
<label for="search-id">
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAQAAAC1+jfqAAABUElEQVQoz2NgAIJ29iBdD0d7X2cPb+tY2f9MDMjgP2O2hKu7vS8CBlisZUNSMJ3fxRMkXO61wm2ue6I3iB1q8Z8ZriDZFCS03fm/wX+1/xp/TBo8QPxeqf+MUAW+QIFKj/+q/wX/c/3n/i/6Qd/bx943z/Q/K1SBI1D9fKv/AhCn/Wf5L5EHdFGKw39OqAIXoPpOMziX4T9/DFBBnuN/HqhAEtCKCNf/XDA/rZRyAmrpsvrPDVUw3wrkqCiLaewg6TohX1d7X0ffs5r/OaAKfinmgt3t4ulr4+Xg4ANip3j+l/zPArNT4LNOD0pAgWCSOUIBy3+h/+pXbBa5tni0eMx23+/mB1YSYnENroT5Pw/QSOX/mkCo+l/jgo0v2KJA643s8PgAmsMBDCbu/5xALHPB2husxN9uCzsDOgAq5kAoaZVnYMCh5Ky1r88Eh/+iABM8jUk7ClYIAAAAAElFTkSuQmCC" alt="Search on Symfony website" />
</label>
<input name="q" id="search-id" type="search" placeholder="Search on Symfony website" />
<button type="submit" class="sf-button">
<span class="border-l">
<span class="border-r">
<span class="btn-bg">OK</span>
</span>
</span>
</button>
</div>
</form>
<div class="help-link">
<a href="https://symfony.com/support">
<span class="icon">{{ include('@Twig/images/icon-support.svg') }}</span>
<span class="hidden-xs-down">Symfony</span> Support
</a>
</div>
</div>
</header>
<div class="sf-reset">
{% block body %}{% endblock %}
</div>
</div>
{% block body %}{% endblock %}
{{ include('@Twig/base_js.html.twig') }}
</body>
</html>
@@ -1,7 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" width="182" height="62" viewBox="45 19 200 80">
<circle cx="68.72" cy="59.18" r="39.19"/>
<path fill="#FFF" d="M85.85 34.5c-3.98.14-7.45 2.33-10.04 5.36-2.85 3.33-4.76 7.28-6.13 11.3-2.46-2-4.35-4.6-8.3-5.74-3.04-.88-6.23-.52-9.18 1.67-1.4 1.04-2.36 2.6-2.82 4.1-1.18 3.83 1.25 7.25 2.35 8.48l2.4 2.58c.5.5 1.7 1.82 1.12 3.72-.63 2.06-3.12 3.4-5.66 2.6-1.15-.35-2.78-1.2-2.4-2.4.14-.47.5-.84.68-1.26.16-.36.25-.63.3-.8.47-1.5-.17-3.48-1.8-3.98-1.5-.47-3.06-.1-3.66 1.85-.7 2.2.38 6.24 6.06 8 6.66 2.03 12.3-1.6 13.1-6.32.5-2.96-.84-5.17-3.3-8l-2-2.2c-1.2-1.2-1.6-3.27-.36-4.86 1.06-1.33 2.56-1.9 5.03-1.23 3.6.96 5.2 3.46 7.87 5.47-1.1 3.63-1.82 7.26-2.48 10.52l-.4 2.42c-1.9 10.03-3.37 15.54-7.16 18.7-.77.55-1.86 1.36-3.5 1.42-.87.03-1.15-.57-1.16-.83-.02-.6.5-.87.83-1.14.5-.28 1.27-.74 1.22-2.2-.06-1.74-1.5-3.25-3.57-3.18-1.56.05-3.93 1.52-3.84 4.2.1 2.77 2.67 4.85 6.57 4.72 2.08-.07 6.73-.92 11.3-6.37 5.34-6.24 6.83-13.4 7.95-18.63l1.25-6.92c.7.1 1.44.15 2.25.16 6.64.14 9.96-3.3 10-5.8.05-1.5-.98-3-2.42-2.97-1.03.03-2.32.72-2.63 2.14-.3 1.4 2.1 2.66.23 3.9-1.34.86-3.75 1.47-7.14.97l.62-3.4c1.25-6.46 2.8-14.4 8.7-14.6.42 0 1.98.03 2.02 1.07 0 .34-.08.43-.48 1.22-.4.62-.57 1.15-.55 1.75.06 1.66 1.3 2.74 3.12 2.68 2.43-.08 3.13-2.44 3.1-3.66-.1-2.85-3.12-4.65-7.1-4.52z"/>
<g>
<path d="M209.92 51.2c5.65 0 9.43 4.08 9.43 9.72 0 5.3-3.86 9.7-9.43 9.7-5.6 0-9.46-4.4-9.46-9.7 0-5.64 3.8-9.72 9.46-9.72zm0 16.67c4 0 5.8-3.64 5.8-6.95 0-3.53-2.16-6.95-5.8-6.95-3.67 0-5.82 3.42-5.82 6.95 0 3.3 1.78 6.95 5.82 6.95zM200 52.93v-1.3h-4.92v-1.76c0-2.5.37-4.4 3.3-4.4H198.6c.8.06 1.5-.6 1.54-1.43l.06-1.12c-.7-.1-1.42-.22-2.3-.22-5.05 0-6.22 2.95-6.22 7.46v1.48h-4.36v1.44c.1.75.75 1.32 1.53 1.32h2.83v15.8h1.9c.77 0 1.42-.6 1.52-1.35V54.4h3.42c.8-.02 1.46-.67 1.5-1.47zM154.44 51.64h-.02c-.72 0-1.42.5-1.73 1.17L148 67h-.08l-4.6-14.2c-.3-.66-1-1.16-1.74-1.16h-2.4l6.3 17.32c.2.62.65 1.56.65 1.97 0 .36-1.02 4.57-4.07 4.57h-.23c-.78-.05-1.37.5-1.5 1.34l-.1 1.18c.62.1 1.25.25 2.34.25 4.5 0 5.85-4.1 7.13-7.67l6.84-18.96h-2.1zM132.7 55.4c-2.83-1.44-5.92-2.42-5.98-5.33 0-3.1 2.85-3.9 5.04-3.9h.02c.95 0 1.7.1 2.45.26h.02c.78.05 1.44-.57 1.54-1.34l.05-1.13c-1.44-.35-2.94-.54-4.24-.54-4.74.03-8.28 2.43-8.3 7 .02 3.98 2.7 5.53 5.6 6.93 2.84 1.36 5.95 2.5 5.98 5.78-.02 3.44-3.34 4.7-5.62 4.72-1.34 0-2.8-.34-4-.73-.78-.13-1.4.55-1.5 1.45l-.1 1c1.67.54 3.4 1 5.13 1 5.34-.03 9.47-2.15 9.5-7.67-.02-4.24-2.73-6.03-5.6-7.5zM184.43 70.2c.74 0 1.35-.53 1.5-1.22V58.3c0-4.04-1.7-7.1-6.43-7.1-1.68 0-4.48.95-5.75 3.6-.98-2.5-3.13-3.6-5.27-3.6-2.73 0-4.6.98-5.9 3.13h-.07v-1.15c0-.85-.7-1.54-1.54-1.54h-1.66V70.2h1.86c.86 0 1.55-.7 1.55-1.56 0-.02.02-.03.03-.05v-7.75c0-3.46 1.38-6.88 4.87-6.88 2.77 0 3.3 2.87 3.3 5.16V70.2h1.9c.8 0 1.46-.63 1.53-1.42v-7.93c0-3.46 1.4-6.88 4.88-6.88 2.77 0 3.32 2.87 3.32 5.16V70.2h1.9zM237.28 70.2c.84 0 1.5-.67 1.55-1.5v-9.53c0-4.98-2.15-7.97-6.96-7.97-2.57 0-5.05 1.28-6.07 3.4h-.07v-1.4c0-.86-.7-1.56-1.55-1.56h-1.77V70.2h1.9c.8 0 1.47-.64 1.54-1.44V61.6c0-4.5 1.75-7.63 5.64-7.63 2.98.18 3.93 2.3 3.93 6.62v9.6h1.88zM255.7 51.64h-.02c-.73 0-1.43.5-1.73 1.17l-4.7 14.2h-.08l-4.6-14.2c-.3-.66-1-1.16-1.73-1.16h-2.4l6.3 17.32c.2.62.65 1.56.65 1.97 0 .36-1.03 4.57-4.1 4.57h-.22c-.77-.05-1.36.5-1.5 1.34l-.1 1.18c.63.1 1.25.25 2.34.25 4.52 0 5.86-4.1 7.13-7.67l6.84-18.96h-2.1z"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.3 KiB

@@ -15,6 +15,9 @@ use Psr\Log\LoggerInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
use Symfony\Bundle\TwigBundle\ContainerAwareRuntimeLoader;
/**
* @group legacy
*/
class ContainerAwareRuntimeLoaderTest extends TestCase
{
public function testLoad()
@@ -265,11 +265,11 @@ class TwigExtensionTest extends TestCase
$container->compile();
$loader = $container->getDefinition('twig.runtime_loader');
$args = $loader->getArgument(1);
$args = $container->getDefinition((string) $loader->getArgument(0))->getArgument(0);
$this->assertArrayHasKey('Symfony\Bridge\Twig\Form\TwigRenderer', $args);
$this->assertArrayHasKey('FooClass', $args);
$this->assertContains('twig.form.renderer', $args);
$this->assertContains('foo', $args);
$this->assertEquals('twig.form.renderer', $args['Symfony\Bridge\Twig\Form\TwigRenderer']->getValues()[0]);
$this->assertEquals('foo', $args['FooClass']->getValues()[0]);
}
private function createContainer()
@@ -277,6 +277,7 @@ class TwigExtensionTest extends TestCase
$container = new ContainerBuilder(new ParameterBag(array(
'kernel.cache_dir' => __DIR__,
'kernel.root_dir' => __DIR__.'/Fixtures',
'kernel.project_dir' => __DIR__,
'kernel.charset' => 'UTF-8',
'kernel.debug' => false,
'kernel.bundles' => array(
@@ -9,12 +9,13 @@
* file that was distributed with this source code.
*/
namespace Symfony\Bundle\TwigBundle\Tests;
namespace Symfony\Bundle\TwigBundle\Tests\Functional;
use Symfony\Component\HttpKernel\Kernel;
use Symfony\Component\Config\Loader\LoaderInterface;
use Symfony\Component\Filesystem\Filesystem;
use Symfony\Bundle\FrameworkBundle\FrameworkBundle;
use Symfony\Bundle\TwigBundle\Tests\TestCase;
use Symfony\Bundle\TwigBundle\TwigBundle;
class CacheWarmingTest extends TestCase
@@ -9,12 +9,13 @@
* file that was distributed with this source code.
*/
namespace Symfony\Bundle\TwigBundle\Tests;
namespace Symfony\Bundle\TwigBundle\Tests\Functional;
use Symfony\Component\HttpKernel\Kernel;
use Symfony\Component\Config\Loader\LoaderInterface;
use Symfony\Component\Filesystem\Filesystem;
use Symfony\Bundle\FrameworkBundle\FrameworkBundle;
use Symfony\Bundle\TwigBundle\Tests\TestCase;
use Symfony\Bundle\TwigBundle\TwigBundle;
class NoTemplatingEntryTest extends TestCase
+10 -6
View File
@@ -16,27 +16,31 @@
}
],
"require": {
"php": ">=5.5.9",
"php": "^5.5.9|>=7.0.8",
"symfony/config": "~3.2",
"symfony/twig-bridge": "^3.2.1",
"symfony/twig-bridge": "^3.3",
"symfony/http-foundation": "~2.8|~3.0",
"symfony/http-kernel": "~2.8.16|~3.1.9|^3.2.2",
"symfony/http-kernel": "^3.3",
"twig/twig": "~1.34|~2.4"
},
"require-dev": {
"symfony/asset": "~2.8|~3.0",
"symfony/stopwatch": "~2.8|~3.0",
"symfony/dependency-injection": "~2.8|~3.0",
"symfony/dependency-injection": "~3.3",
"symfony/expression-language": "~2.8|~3.0",
"symfony/finder": "~2.8|~3.0",
"symfony/form": "~2.8|~3.0",
"symfony/routing": "~2.8|~3.0",
"symfony/templating": "~2.8|~3.0",
"symfony/yaml": "~2.8|~3.0",
"symfony/framework-bundle": "^3.2.2",
"symfony/framework-bundle": "^3.2.8",
"symfony/web-link": "~3.3",
"doctrine/annotations": "~1.0",
"doctrine/cache": "~1.0"
},
"conflict": {
"symfony/dependency-injection": "<3.3"
},
"autoload": {
"psr-4": { "Symfony\\Bundle\\TwigBundle\\": "" },
"exclude-from-classmap": [
@@ -46,7 +50,7 @@
"minimum-stability": "dev",
"extra": {
"branch-alias": {
"dev-master": "3.2-dev"
"dev-master": "3.3-dev"
}
}
}