* 2.8:
use Precise on Travis to keep PHP LDAP support
fix(security): ensure the 'route' index is set before attempting to use it
[WebProfilerBundle] Fix full sized dump hovering in toolbar
This PR was merged into the 4.0-dev branch.
Discussion
----------
[Console] Make SymfonyQuestionHelper::ask optional by default
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes (nothing in core depends on it)
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!--highly recommended for new features-->
i noticed when writing commands i always keep doing
```php
$io = new SymfonyStyle($input, $output);
$answer = $io->ask('...', null, function ($value) { return $value; });
// instead of just
$answer = $io->ask('...');
```
only to bypass a built-in validation, of which im not sure why it's there. Note the base question helper doesnt make this assumption...
Commits
-------
2da429cd0a [Console] Make SymfonyQuestionHelper::ask optional by default
- added `Symfony\Component\Cache\PruneableInterface` so PSR-6 or PSR-16 cache implementations can declare support
for manual stale cache pruning
- added FilesystemTrait::prune() and PhpFilesTrait::prune() implementations
- now FilesystemAdapter, PhpFilesAdapter, FilesystemCache, and PhpFilesCache implement PruneableInterface and
supports manual stale cache pruning
- Added `cache:pool:prune` command via `Symfony\Bundle\FrameworkBundle\Command\CachePoolPruneCommand` to allow
manual stale cache item pruning of supported PSR-6 and PSR-16 cache pool implementations
- Added `Symfony\Bundle\FrameworkBundle\DependencyInjection\Compiler\CachePoolPrunerPass` compiler pass to fetch
all cache pools implementing `PruneableInterface` and pass them to the command as an `IteratorArgument` so
these references are lazy loaded by the command
- updated changelogs as appropriate
This PR was merged into the 2.8 branch.
Discussion
----------
[WebProfilerBundle] Fix full sized dump hovering in toolbar
| Q | A
| ------------- | ---
| Branch? | 2.8 <!-- see comment below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | #23563 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Since #22953, the dump block shown on hovering the toolbar item takes the full width. But at least on OS X chrome, safari and firefox, the behavior is buggy and makes it unusable as the cursor can't reach the dumped content:
![juin-29-2017 21-09-38](https://user-images.githubusercontent.com/2211145/27705877-b25c1496-5d0f-11e7-8fff-169e080e335c.gif)
Honestly, I don't really understand the issue here and tried some tweaks until it works everywhere, (including trying to add a `.no-resize` class on `sf-toolbar-info` to avoid executing the related js event listener in case it was conflicting).
As shown in the screenshot, it also fixes the case where the dump wasn't full width under a certain size.
Commits
-------
28930c5 [WebProfilerBundle] Fix full sized dump hovering in toolbar
* 3.3:
[Security] added more tests
[Security] fixed default target path when referer contains a query string
[Security] simplified tests
[Security] refactored tests
[WebProfilerBundle][TwigBundle] Fix infinite js loop on exception pages
[FrameworkBundle] fix ValidatorCacheWarmer: use serializing ArrayAdapter
Change "this" to "that" to avoid confusion
[VarDumper] Move locale sniffing to dump() time
[VarDumper] Use "C" locale when using "comma" flags
[Config] Make ClassExistenceResource throw on invalid parents
This PR was merged into the 3.4 branch.
Discussion
----------
[DebugBundle] Added min_depth to Configuration
This enables calling the recently-added `setMinDepth` function on `VarCloner`.
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR | symfony/symfony-docs#8185
Commits
-------
30cd70d [DebugBundle] Added min_depth to Configuration
* 3.4: (22 commits)
Fix lazy commands registration
[TwigBridge] deprecate TwigRenderer
[FrameworkBundle] Set default public directory on install assets
[Security] Fix wrong term in UserProviderInterface
[HttpFoundation] Set meta refresh time to 0 in RedirectResponse content
disable inlining deprecated services
[Stopwatch] Fix precision for root section
[Cache] add constructor docblocks for clarity
[WebServerBundle] allowed public/ root directory to be auto-discovered along side web/
[WebServerBundle] remove duplicate code
[SecurityBundle] Clarify deprecation in UserPasswordEncoderCommand::getContainer
[Profiler][Validator] ValidatorDataCollector: use new DataCollector::getCasters() method
[Profiler] Fix data collector getCasters() call
[VarDumper] Added setMinDepth to VarCloner
remove symfony/process suggestion
[DI] Remove unused dynamic property
[Cache] add constructor docblocks for clarity
[Security] validate empty passwords again
[Process] Fixed issue between process builder and exec
non-conflicting anonymous service ids across files
...
* 3.3:
[FrameworkBundle] Set default public directory on install assets
[Security] Fix wrong term in UserProviderInterface
[HttpFoundation] Set meta refresh time to 0 in RedirectResponse content
disable inlining deprecated services
[Cache] add constructor docblocks for clarity
[WebServerBundle] allowed public/ root directory to be auto-discovered along side web/
[WebServerBundle] remove duplicate code
[SecurityBundle] Clarify deprecation in UserPasswordEncoderCommand::getContainer
[Cache] add constructor docblocks for clarity
[Security] validate empty passwords again
[DI] Remove irrelevant comment from container
[TwigBridge] cleaner implementation of the TwigRenderer
This PR was squashed before being merged into the 3.3 branch (closes#23513).
Discussion
----------
[FrameworkBundle] Set default public directory on install assets
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
After https://github.com/symfony/flex/pull/122 and https://github.com/symfony/recipes/pull/106 the default directory to install assets is `public`.
Commits
-------
1bdfe0b39b [FrameworkBundle] Set default public directory on install assets
This PR was squashed before being merged into the 3.3 branch (closes#23535).
Discussion
----------
Make server:* commands work out of the box with the public/ root dir
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
The first commit removes code that is not needed as the WebserverConfig class already throws the exact same error and the display is exactly the same in that case.
The second commit adds support for `public/` along side `web/`.
Commits
-------
34c8566be1 [WebServerBundle] allowed public/ root directory to be auto-discovered along side web/
bc6b57c208 [WebServerBundle] remove duplicate code
* 3.3:
[Profiler] Fix data collector getCasters() call
remove symfony/process suggestion
[DI] Remove unused dynamic property
[Process] Fixed issue between process builder and exec
non-conflicting anonymous service ids across files
This PR was merged into the 4.0-dev branch.
Discussion
----------
[DI] Remove remaining deprecated features
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
* removed autowiring services based on the types they implement
* removed the `DefinitionDecorator` class, replaced by `ChildDefinition`
* removed the `AutowireServiceResource` class and related `AutowirePass::createResourceForClass()` method
* removed `LoggingFormatter`, `Compiler::getLoggingFormatter()` and `addLogMessage()` class and methods, use the `ContainerBuilder::log()` method instead
* removed `FactoryReturnTypePass`
* removed `ContainerBuilder::addClassResource()`, use the `addObjectResource()` or the `getReflectionClass()` method instead.
* removed support for top-level anonymous services
* removed silent behavior for unused attributes and elements
* Removed the "framework.validation.cache" configuration option. Configure the "cache.validator" service under "framework.cache.pools" instead.
Commits
-------
4bd7b921f4 [DI] Remove remaining deprecated features
* 3.4:
Add TokenProcessor
[DI] Handle root namespace in service definitions
Add support for command lazy-loading
Use rawurlencode() to transform the Cookie into a string
[TwigBundle] Added a RuntimeExtensionInterface to take advantage of autoconfigure
[Process] Fix parsing args on Windows
Add exculde verbosity test
[HttpKernel][VarDumper] Truncate profiler data & optim perf
[DI] Allow imports in string format for YAML
[Validator] Allow to use a property path to get value to compare in comparison constraints
[Security] Fix authentication.failure event not dispatched on AccountStatusException
add option to define the access decision manager
Add support for doctrin/dbal 2.6 types
This PR was merged into the 3.4 branch.
Discussion
----------
[Console] Add support for command lazy-loading
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/12063https://github.com/symfony/symfony/pull/16438https://github.com/symfony/symfony/pull/13946#21781
| License | MIT
| Doc PR | todo
This PR adds command lazy-loading support to the console, based on PSR-11 and DI tags.
(https://github.com/symfony/symfony/issues/12063#issuecomment-57173784)
Commands registered as services which set the `command` attribute on their `console.command` tag are now instantiated when calling `Application::get()` instead of all instantiated at `run()`.
__Usage__
```yaml
app.command.heavy:
tags:
- { name: console.command, command: app:heavy }
```
This way private command services can be inlined (no public aliases, remain really private).
With console+PSR11 implem only:
```php
$application = new Application();
$container = new ServiceLocator(['heavy' => function () { return new Heavy(); }]);
$application->setCommandLoader(new ContainerCommandLoader($container, ['app:heavy' => 'heavy']);
```
Implementation is widely inspired from Twig runtime loaders (without the definition/runtime separation which is not needed here).
Commits
-------
7f97519 Add support for command lazy-loading
This PR was merged into the 3.4 branch.
Discussion
----------
[Security] make it possible to configure a custom access decision manager service
| Q | A |
| --- | --- |
| Branch? | 3.4 |
| Bug fix? | no |
| New feature? | yes |
| BC breaks? | no |
| Deprecations? | no |
| Tests pass? | yes |
| Fixed tickets | #942, #14049, #15295, #16828, #16843, |
| License | MIT |
| Doc PR | TODO |
These changes will make it possible to let users define their own voting strategies without the need for custom compiler passes that replace the built-in `AccessDecisionManager` (see linked issues in the PR table for some use cases).
Commits
-------
e0913a2 add option to define the access decision manager
* 3.4: (23 commits)
Don't display the Symfony debug toolbar when printing the page
[Routing] also add matched params for redirect due to trailing slash
do not wire namespaces for the ArrayAdapter
check _controller attribute is a string before parsing it
[Cache] Added test for ApcuAdapter when using in CLI
[Validator] sync upgrade file with latest code changes
allow to configure custom formats in XML configs
[HttpKernel] fix DumpDataCollector tests
[FrameworkBundle] fix changelog
[WebProfilerBundle] Cleanup profiler leftover
[Routing] Add matched and default parameters to redirect responses
[DotEnv] Fix variable substitution
require the XML PHP extension
Fix phpdoc for serializer normalizers exceptions
Fixed absolute url generation for query strings and hash urls
bumped Symfony version to 2.8.25
updated VERSION for 2.8.24
updated CHANGELOG for 2.8.24
bumped Symfony version to 2.7.32
[Filesystem] Dont copy perms when origin is remote
...
* 3.3:
Don't display the Symfony debug toolbar when printing the page
do not wire namespaces for the ArrayAdapter
check _controller attribute is a string before parsing it
[Cache] Added test for ApcuAdapter when using in CLI
allow to configure custom formats in XML configs
[HttpKernel] fix DumpDataCollector tests
[FrameworkBundle] fix changelog
[WebProfilerBundle] Cleanup profiler leftover
[DotEnv] Fix variable substitution
require the XML PHP extension
Fix phpdoc for serializer normalizers exceptions
Fixed absolute url generation for query strings and hash urls
bumped Symfony version to 2.8.25
updated VERSION for 2.8.24
updated CHANGELOG for 2.8.24
bumped Symfony version to 2.7.32
[Filesystem] Dont copy perms when origin is remote
updated VERSION for 2.7.31
update CONTRIBUTORS for 2.7.31
updated CHANGELOG for 2.7.31
* 3.2:
Don't display the Symfony debug toolbar when printing the page
do not wire namespaces for the ArrayAdapter
[Cache] Added test for ApcuAdapter when using in CLI
allow to configure custom formats in XML configs
[HttpKernel] fix DumpDataCollector tests
[FrameworkBundle] fix changelog
[WebProfilerBundle] Cleanup profiler leftover
require the XML PHP extension
Fix phpdoc for serializer normalizers exceptions
Fixed absolute url generation for query strings and hash urls
bumped Symfony version to 2.8.25
updated VERSION for 2.8.24
updated CHANGELOG for 2.8.24
bumped Symfony version to 2.7.32
[Filesystem] Dont copy perms when origin is remote
updated VERSION for 2.7.31
update CONTRIBUTORS for 2.7.31
updated CHANGELOG for 2.7.31
* 2.8:
Don't display the Symfony debug toolbar when printing the page
allow to configure custom formats in XML configs
require the XML PHP extension
Fixed absolute url generation for query strings and hash urls
bumped Symfony version to 2.8.25
updated VERSION for 2.8.24
updated CHANGELOG for 2.8.24
bumped Symfony version to 2.7.32
[Filesystem] Dont copy perms when origin is remote
updated VERSION for 2.7.31
update CONTRIBUTORS for 2.7.31
updated CHANGELOG for 2.7.31
* 2.7:
allow to configure custom formats in XML configs
require the XML PHP extension
Fixed absolute url generation for query strings and hash urls
bumped Symfony version to 2.7.32
[Filesystem] Dont copy perms when origin is remote
updated VERSION for 2.7.31
update CONTRIBUTORS for 2.7.31
updated CHANGELOG for 2.7.31
The `framework.serializer.cache` option was also deprecated in Symfony
3.1. This was documented in the upgrade file, but was not reflected in
the bundle's changelog.
* 3.4:
Deprecate support for stacked errors
fixed tests
[HttpFoundation] Find the original request protocol version
fixed CS
Add support for microseconds in Stopwatch
Preserve HttpOnly value when deserializing a header
add minimum and maximum amount of pixels to Image validator
fixed CHANGELOG
[DX] [TwigBundle] Enhance the new exception page design
[BrowserKit] Emulate back/forward browser navigation
Fix deprecated message
[Component][Serializer][Normalizer] : Deal it with Has Method for the Normalizer/Denormalizer
[Validator] improve the changelog
[FrameworkBundle] Wire inner translator
[FrameworkBundle][HttpKernel] Move addcachearmer, addcacheclearer compiler pass
[FrameworkBundle][Translation] Move translation compiler pass
* 3.3: (33 commits)
Preserve HttpOnly value when deserializing a header
[DX] [TwigBundle] Enhance the new exception page design
Fix deprecated message
[DI][Security] Prevent unwanted deprecation notices when using Expression Languages
bumped Symfony version to 3.3.5
updated VERSION for 3.3.4
updated CHANGELOG for 3.3.4
[VarDumper] Reduce size of serialized Data objects
bumped Symfony version to 3.2.12
updated VERSION for 3.2.11
updated CHANGELOG for 3.2.11
fixed bad merge
Fix indent of methods
[Cache] Handle APCu failures gracefully
[DoctrineBridge] Use normalizedIds for resetting entity manager services
[FrameworkBundle] Do not remove files from assets dir
[FrameworkBundle] 3.3: Don't get() private services from debug:router
bumped Symfony version to 3.3.4
updated VERSION for 3.3.3
updated CHANGELOG for 3.3.3
...
This PR was squashed before being merged into the 3.3 branch (closes#22439).
Discussion
----------
[DX] [TwigBundle] Enhance the new exception page design
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
- [x] Fix the problem with wrapping wide lines (https://github.com/symfony/symfony/pull/20951#issuecomment-292201983)
I got motivated by recent PR https://github.com/symfony/symfony/pull/20951 and redesigned the exception page even more.
Compare before: ![before](https://cloud.githubusercontent.com/assets/885946/25052220/0756b74e-2151-11e7-98b6-c99fd9eaabec.png)
with after: ![after](https://cloud.githubusercontent.com/assets/885946/25052225/0c76581a-2151-11e7-96ff-eb502ee8e97b.png)
(Ignore the the "sf" toolbar icon in the middle of the page. This is how Firefox does full-page screenshots.)
The most noticeable changes:
- removed double line spacing (it just does not feel natural)
- file context increased from 3 to 10 lines (it helps me to better orientate in the code)
- added horizontal scrollbar for the cases when the code is wider
- the highlighted line color is more saturated in order to be noticed easily
Commits
-------
43212b9a90 [DX] [TwigBundle] Enhance the new exception page design
* 3.3: (21 commits)
fixed bad merge
Fix indent of methods
[Cache] Handle APCu failures gracefully
[FrameworkBundle] Do not remove files from assets dir
[FrameworkBundle] 3.3: Don't get() private services from debug:router
bumped Symfony version to 3.3.4
updated VERSION for 3.3.3
updated CHANGELOG for 3.3.3
bumped Symfony version to 3.2.11
updated VERSION for 3.2.10
updated CHANGELOG for 3.2.10
bumped Symfony version to 2.8.24
updated VERSION for 2.8.23
updated CHANGELOG for 2.8.23
Don't access private services from container aware commands (deprecated)
bumped Symfony version to 2.7.31
updated VERSION for 2.7.30
update CONTRIBUTORS for 2.7.30
updated CHANGELOG for 2.7.30
call setContainer() for autowired controllers
...
* 3.2:
fixed bad merge
[Cache] Handle APCu failures gracefully
[FrameworkBundle] Do not remove files from assets dir
bumped Symfony version to 3.2.11
updated VERSION for 3.2.10
updated CHANGELOG for 3.2.10
bumped Symfony version to 2.8.24
updated VERSION for 2.8.23
updated CHANGELOG for 2.8.23
bumped Symfony version to 2.7.31
updated VERSION for 2.7.30
update CONTRIBUTORS for 2.7.30
updated CHANGELOG for 2.7.30
* 2.8:
[FrameworkBundle] Do not remove files from assets dir
bumped Symfony version to 2.8.24
updated VERSION for 2.8.23
updated CHANGELOG for 2.8.23
bumped Symfony version to 2.7.31
updated VERSION for 2.7.30
update CONTRIBUTORS for 2.7.30
updated CHANGELOG for 2.7.30
* 2.7:
[FrameworkBundle] Do not remove files from assets dir
bumped Symfony version to 2.7.31
updated VERSION for 2.7.30
update CONTRIBUTORS for 2.7.30
updated CHANGELOG for 2.7.30
This PR was merged into the 3.3 branch.
Discussion
----------
[FrameworkBundle] call setContainer() for autowired controllers
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #23200, FriendsOfSymfony/FOSRestBundle#1719
| License | MIT
| Doc PR |
Previously, you either did not use controllers as services or you explicitly wired everything yourself. In case of a non-service controller the FrameworkBundle took care of calling `setContainer()` inside the `instantiateController()` method:
```php
protected function instantiateController($class)
{
$controller = parent::instantiateController($class);
if ($controller instanceof ContainerAwareInterface) {
$controller->setContainer($this->container);
}
if ($controller instanceof AbstractController && null !== $previousContainer = $controller->setContainer($this->container)) {
$controller->setContainer($previousContainer);
}
return $controller;
}
```
With the new autowired controllers as services this is no longer happening as controllers do not need to be instantiated anymore (the container already returns fully built objects).
Commits
-------
1d07a28 call setContainer() for autowired controllers
* 3.4:
[Console] Fix descriptor tests
Change wording from object to subject
add changelog entry for Stopwatch::reset()
Add DateCaster
[Dotenv] parse concatenated variable values
[Yaml] deprecate the !str tag
Add filter in VarDumperTestTrait
Support for parsing PHP constants in yaml loader
This PR was merged into the 3.4 branch.
Discussion
----------
Change wording from object to subject
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| License | MIT
The authorization checker has been changed to support any value
recently. The naming should reflect that to avoid confusion.
Refs https://github.com/sonata-project/SonataAdminBundle/issues/4518
Commits
-------
d261894c6e Change wording from object to subject
* 3.4:
Misspelled word
Display a better error design when the toolbar cannot be displayed
fixed CS
do not validate empty values
[Cache] fix cleanup of expired items for PdoAdapter
[Dotenv] clean up before running assertions
[Console] fix description of INF default values
parse escaped quotes in unquoted env var values
[PropertyAccess] Fix TypeError discard
[Validator] Throw exception on Comparison constraints null options
[FrameworkBundle] Display a proper warning on cache:clear without the --no-warmup option
[Security] Fix Firewall ExceptionListener priority
Allow * to bind all interfaces (as INADDR_ANY)
Identify tty tests in Component/Process
[Workflow] Added more events to the announce function
[Validator] Remove property path suggestion for using the Expression validator
[WebProfilerBundle] Fix css trick used for offsetting html anchor from fixed header
disable unusable fragment renderers
[Stopwatch] Add a reset method
[Security] Fix annotation
* 3.3:
Misspelled word
Display a better error design when the toolbar cannot be displayed
do not validate empty values
[Cache] fix cleanup of expired items for PdoAdapter
[Dotenv] clean up before running assertions
[Console] fix description of INF default values
parse escaped quotes in unquoted env var values
[PropertyAccess] Fix TypeError discard
[Validator] Throw exception on Comparison constraints null options
[FrameworkBundle] Display a proper warning on cache:clear without the --no-warmup option
[Security] Fix Firewall ExceptionListener priority
Identify tty tests in Component/Process
[Workflow] Added more events to the announce function
[Validator] Remove property path suggestion for using the Expression validator
[WebProfilerBundle] Fix css trick used for offsetting html anchor from fixed header
[Security] Fix annotation
* 3.2:
Misspelled word
Display a better error design when the toolbar cannot be displayed
do not validate empty values
[Cache] fix cleanup of expired items for PdoAdapter
[Console] fix description of INF default values
[PropertyAccess] Fix TypeError discard
[Validator] Throw exception on Comparison constraints null options
Identify tty tests in Component/Process
[Workflow] Added more events to the announce function
[Validator] Remove property path suggestion for using the Expression validator
[WebProfilerBundle] Fix css trick used for offsetting html anchor from fixed header
[Security] Fix annotation
* 2.8:
Misspelled word
Display a better error design when the toolbar cannot be displayed
do not validate empty values
[Console] fix description of INF default values
[PropertyAccess] Fix TypeError discard
[Validator] Throw exception on Comparison constraints null options
Identify tty tests in Component/Process
[Security] Fix annotation
* 2.7:
Misspelled word
Display a better error design when the toolbar cannot be displayed
do not validate empty values
[Console] fix description of INF default values
[PropertyAccess] Fix TypeError discard
[Validator] Throw exception on Comparison constraints null options
Identify tty tests in Component/Process
[Security] Fix annotation
This PR was squashed before being merged into the 2.7 branch (closes#23274).
Discussion
----------
Display a better error design when the toolbar cannot be displayed
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes (failure unrelated)
| Fixed tickets | https://github.com/symfony/symfony/pull/23266
| License | MIT
| Doc PR | n/a
Fixing the left position of the bar (tested in app without style) and escaping the literal newline (ES5) as some IDEs fails with previous syntax (and Github diff too). Btw, I have added the Symfony icon to make clear that this message comes from Symfony ;)
**Before:**
![current_toolbar_error](https://user-images.githubusercontent.com/2028198/27466735-cd5f0da8-57aa-11e7-8431-3025c41557e6.png)
**After:**
![after_toolbar_27](https://user-images.githubusercontent.com/2028198/27467928-75e45d4e-57b4-11e7-9e1f-e252d9085596.png)
Commits
-------
ed3e403b4b Display a better error design when the toolbar cannot be displayed
This PR was merged into the 3.4 branch.
Discussion
----------
[WebServer] Allow * to bind all interfaces (as INADDR_ANY)
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | no-tests
| Fixed tickets | ~
| License | MIT
| Doc PR |
In Python and elsewhere, binding to '*' means '0.0.0.0' (INADDR_ANY). I just added that to WebServer command.
Commits
-------
1880bcfde2 fixed CS
b31ebae4cb Allow * to bind all interfaces (as INADDR_ANY)
* 3.4:
fixed tests
swiftmailer bridge is gone
respect the API in FirewallContext map
[TwigBundle] add back exception check
Dont call count on non countable object
Fix undefined variable $filesystem
* 3.3:
fixed tests
swiftmailer bridge is gone
respect the API in FirewallContext map
[TwigBundle] add back exception check
Dont call count on non countable object
Fix undefined variable $filesystem
* 3.2:
fixed tests
swiftmailer bridge is gone
[TwigBundle] add back exception check
Dont call count on non countable object
Fix undefined variable $filesystem
* 3.4: (83 commits)
add missing version attribute
Show exception is checked twice in ExceptionController of twig
allow SSI fragments configuration in XML files
Display a better error message when the toolbar cannot be displayed
[SecurityBundle] Add user impersonation info and exit action to the profiler
render hidden _method field in form_rest()
Add Doctrine Cache to dev dependencies to fix failing unit tests.
return fallback locales whenever possible
Fix Predis client cluster with pipeline
[Dotenv] Test load() with multiple paths
[Console] Fix catching exception type in QuestionHelper
Improved the exception page when there is no message
[WebProfilerBundle] Eliminate line wrap on count columnt (routing)
[Profiler][Validator] Add a validator panel in profiler
[Validator] replace hardcoded service id
[Routing] Fix XmlFileLoader exception message
Remove duplicate changelog entries
[DI] Dedup tags when using instanceof/autoconfigure
[Translation] Fix FileLoader::loadResource() php doc
[Serializer] Fix workaround min php version
...
* 3.3: (64 commits)
Show exception is checked twice in ExceptionController of twig
allow SSI fragments configuration in XML files
Display a better error message when the toolbar cannot be displayed
render hidden _method field in form_rest()
Add Doctrine Cache to dev dependencies to fix failing unit tests.
return fallback locales whenever possible
Fix Predis client cluster with pipeline
[Dotenv] Test load() with multiple paths
[Console] Fix catching exception type in QuestionHelper
Improved the exception page when there is no message
[WebProfilerBundle] Eliminate line wrap on count columnt (routing)
[Validator] replace hardcoded service id
[Routing] Fix XmlFileLoader exception message
[DI] Dedup tags when using instanceof/autoconfigure
[Translation] Fix FileLoader::loadResource() php doc
Sessions: configurable "use_strict_mode" option for NativeSessionStorage
[FrameworkBundle] [Command] Clean bundle directory, fixes#23177
fixed CS
[WebProfilerBundle] Fix the icon for the Cache panel
[WebServerBundle] Fix router script path and check existence
...
* 3.2: (42 commits)
Show exception is checked twice in ExceptionController of twig
allow SSI fragments configuration in XML files
Display a better error message when the toolbar cannot be displayed
render hidden _method field in form_rest()
Add Doctrine Cache to dev dependencies to fix failing unit tests.
return fallback locales whenever possible
[Console] Fix catching exception type in QuestionHelper
[WebProfilerBundle] Eliminate line wrap on count columnt (routing)
[Routing] Fix XmlFileLoader exception message
[Translation] Fix FileLoader::loadResource() php doc
Sessions: configurable "use_strict_mode" option for NativeSessionStorage
[FrameworkBundle] [Command] Clean bundle directory, fixes#23177
Reset redirectCount when throwing exception
[TwigBundle] Remove template.xml services when templating is disabled
add content-type header on exception response
Embedding a response that combines expiration and validation, that should not defeat expiration on the combined response
fixed bad merge
Fix two edge cases in ResponseCacheStrategy
[Routing] Expose request in route conditions, if needed and possible
[Routing] Expose request in route conditions, if needed and possible
...
* 2.8: (40 commits)
Show exception is checked twice in ExceptionController of twig
allow SSI fragments configuration in XML files
Display a better error message when the toolbar cannot be displayed
render hidden _method field in form_rest()
return fallback locales whenever possible
[Console] Fix catching exception type in QuestionHelper
[WebProfilerBundle] Eliminate line wrap on count columnt (routing)
[Routing] Fix XmlFileLoader exception message
[Translation] Fix FileLoader::loadResource() php doc
Sessions: configurable "use_strict_mode" option for NativeSessionStorage
[FrameworkBundle] [Command] Clean bundle directory, fixes#23177
Reset redirectCount when throwing exception
[TwigBundle] Remove template.xml services when templating is disabled
add content-type header on exception response
Embedding a response that combines expiration and validation, that should not defeat expiration on the combined response
Fix two edge cases in ResponseCacheStrategy
[Routing] Expose request in route conditions, if needed and possible
[Routing] Expose request in route conditions, if needed and possible
[Translation][FrameworkBundle] Fix resource loading order inconsistency reported in #23034
[Filesystem] added workaround in Filesystem::rename for PHP bug
...
* 2.7:
Show exception is checked twice in ExceptionController of twig
allow SSI fragments configuration in XML files
Display a better error message when the toolbar cannot be displayed
render hidden _method field in form_rest()
return fallback locales whenever possible
This PR was merged into the 2.7 branch.
Discussion
----------
Display a better error message when the toolbar cannot be displayed
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #23264
| License | MIT
| Doc PR | -
In action:
![profiler-error](https://user-images.githubusercontent.com/73419/27444352-5d0a1d60-5776-11e7-89c3-430cd6f38454.png)
Commits
-------
cc7275bccc Display a better error message when the toolbar cannot be displayed
* 2.7:
[Routing] Fix XmlFileLoader exception message
Sessions: configurable "use_strict_mode" option for NativeSessionStorage
[FrameworkBundle] [Command] Clean bundle directory, fixes#23177
Reset redirectCount when throwing exception
[TwigBundle] Remove template.xml services when templating is disabled
add content-type header on exception response
Embedding a response that combines expiration and validation, that should not defeat expiration on the combined response
Fix two edge cases in ResponseCacheStrategy
[Routing] Expose request in route conditions, if needed and possible
[Routing] Expose request in route conditions, if needed and possible
[Translation][FrameworkBundle] Fix resource loading order inconsistency reported in #23034
[Filesystem] added workaround in Filesystem::rename for PHP bug
Add tests for ResponseCacheStrategy to document some more edge cases
[HttpFoundation] added missing docs
fixes#21606
[VarDumper] fixes
[Security] fix switch user _exit without having current token
This PR was squashed before being merged into the 2.7 branch (closes#23195).
Discussion
----------
[FrameworkBundle] [Command] Clean bundle directory, fixes#23177
| Q | A
| ------------- | ---
| Branch? | 2.7 <!-- see comment below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | no
| Fixed tickets | #23177
| License | MIT
This PR fix#23177
when running an assets:install, it will remove directorys who do not have anymore a valid Bundle
Commits
-------
180f178f43 [FrameworkBundle] [Command] Clean bundle directory, fixes#23177
This PR was squashed before being merged into the 3.3 branch (closes#23160).
Discussion
----------
[WebProfilerBundle] Fix the icon for the Cache panel
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #23159
| License | MIT
| Doc PR | -
Commits
-------
50c1d478ce [WebProfilerBundle] Fix the icon for the Cache panel
This PR was merged into the 2.7 branch.
Discussion
----------
[TwigBundle] Add Content-Type header for exception response
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
This PR comes after I was looking to customize the way exceptions are served for a JSON API (grabbed the info at http://symfony.com/doc/current/controller/error_pages.html#overriding-the-default-exceptioncontroller).
I noticed that even when changing the request format to 'json' so that the right json.twig template is served:
```php
// in my override of the ExceptionController
public function showAction(Request $request, FlattenException $exception, DebugLoggerInterface $logger = null)
{
$request->setRequestFormat('json');
return parent::showAction($request, $exception, $logger);
}
```
the response Content-Type header was still 'text/html'.
By now, the response Content-Type should be corresponding to the given request format.
I also feel there's some room for improvement with the general "displaying error for a JSON API" chapter as it feels strange that there's no configuration option to just say "serve me anything as json", but that's another issue.
Commits
-------
9e2b408f25 add content-type header on exception response
This PR was merged into the 3.3 branch.
Discussion
----------
[WebServerBundle] Fix router script option BC
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #23206
| License | MIT
| Doc PR | -
Server commands does not work with router script given by a relative path eg.:
```
bin/console server:run -r router.php
```
but, this was working before and was removed (by accident I guess) in https://github.com/symfony/symfony/pull/21039/files#diff-b915f83f99a4166eb34eab581a92501bL187
Commits
-------
aeab2fe1f7 [WebServerBundle] Fix router script path and check existence
This PR was merged into the 3.3 branch.
Discussion
----------
[FrameworkBundle] Expose the AbstractController's container to its subclasses
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
This is useful if an application provides their own base Controller that
references items in the container. It also makes it simpler for that
base controller to add additional optional dependencies by only overriding
getSubscribedServices instead of having to reimplement setContainer and
use ControllerTrait.
Commits
-------
ee17131fca Expose the AbstractController's container to its subclasses
This PR was squashed before being merged into the 3.4 branch (closes#22629).
Discussion
----------
[Security] Trigger a deprecation when a voter is missing the VoterInterface
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Right now it's possible to add voters to the access decision manager that do not have a `VoterInterface`.
- No Interface, no `vote()` method, and it will give a PHP error.
- No Interface, but `vote()` method, it will still work.
- If I don't implement the interface _and_ have no `vote()` method, I will get weird exception that's not meaningful: `Attempted to call an undefined method named "vote" of class "App\Voter\MyVoter".`
This PR will deprecate the ability to use voters without the interface, it will also throw a proper exception when missing the interface _and_ the `vote()` method. Why when using and not when setting? Due to the fact that the voters can be set lazily via the `IteratorArgument`. The SecurityBundle will trigger a deprecation if the interface is not implemented and an exception if there's not even a `vote()` method present (to prevent exceptions at run-time).
This should have full backwards compatibility with 3.3, but give more meaningful errors. The only behavioral difference, might be that the container will throw an exception instead of maybe succeeding in voting when 1 voter would be broken at the end of the list (based on strategy). This case however, will be detected during development and deployment, rather than run-time.
Commits
-------
9c253e1ff6 [Security] Trigger a deprecation when a voter is missing the VoterInterface
Useful if an application provides their own base Controller that
references items in the container. It also makes it simpler for that
base controller to add additional optional dependencies by only overriding
getSubscribedServices instead of having to reimplement setContainer and
use ControllerTrait.
* 3.2:
[SecurityBundle] Move cache of the firewall context into the request parameters
Fix Usage with anonymous classes
[Workflow] Added more keywords in the composer.json
[Cache] APCu isSupported() should return true when apc.enable_cli=Off
[PropertyAccess] Do not silence TypeErrors from client code.
This PR was squashed before being merged into the 3.3 branch (closes#23088).
Discussion
----------
[FrameworkBundle] Dont set pre-defined esi/ssi services
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | not sure
| Deprecations? | no
| Tests pass? | yes/no
| Fixed tickets | #23080
| License | MIT
| Doc PR | symfony/symfony-docs#... <!--highly recommended for new features-->
It fixes the issue, but im not sure what's expected if you dont use http cache (solely enabled ssi/esi in config). Before the services were initialized, now they are synthetic as http cache sets them, but thats optional =/
Commits
-------
8c26aab0fe [FrameworkBundle] Dont set pre-defined esi/ssi services
This PR was squashed before being merged into the 2.7 branch (closes#23057).
Discussion
----------
[Translation][FrameworkBundle] Fix resource loading order inconsistency reported in #23034
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #23034
| License | MIT
| Doc PR |
Fixes the bug reported in #23034:
When mixing `addResource()` calls and providing the `resource_files` option, the order in which resources are loaded depends on the `kernel.debug` setting and whether a cache is used.
In particular, when several loaders provide translations for the same message, the one that "wins" may change between development and production mode.
Commits
-------
2a9e65dea9 [Translation][FrameworkBundle] Fix resource loading order inconsistency reported in #23034
This PR was squashed before being merged into the 3.4 branch (closes#23154).
Discussion
----------
[WebProfilerBundle] Sticky ajax window
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #23125
| License | MIT
| Doc PR | -
This toggles the ajax toolbar block being sticky on click. I find it quite useful in heavy ajax apps :)
Not sure the state needs to be persisted in local storage or so, could be done :) however for our app all the navigating happens via react router, hence no real need for us to persist it between requests.
Commits
-------
b92929b0be [WebProfilerBundle] Sticky ajax window
This PR was merged into the 3.3 branch.
Discussion
----------
Fix AutowiringTypesTest transient tests
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
In 3.3, we have a race condition because FrameworkBundle and SecurityBundle use the same test folder for their respective AutowiringTypesTest.
Commits
-------
408e56e404 Fix AutowiringTypesTest transient tests
* 3.4:
[FrameworkBundle] Deprecate useless --no-prefix option
Add Doctrine Cache to dev dependencies to fix failing unit tests.
Give info about called security listeners in profiler
Fix the usage of FrameworkBundle in debug mode without Stopwatch
This PR was merged into the 3.4 branch.
Discussion
----------
[FrameworkBundle] Deprecate useless --no-prefix option
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
It was a workaround, not needed since https://github.com/symfony/symfony/pull/21228. Let's deprecate it and remove it in 4.0.
Commits
-------
f7afa777d8 [FrameworkBundle] Deprecate useless --no-prefix option
This PR was merged into the 3.4 branch.
Discussion
----------
[TwigBundle] Add Doctrine Cache to dev dependencies to fix failing unit tests
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | None
| License | MIT
| Doc PR | N/A
Currently, the unit tests of TwigBundle are failing because Doctrine Cache is missing. Before the changes of #23131, this dependency was pulled via FrameworkBundle. This PR adds Doctrine Cache to the dev dependencies of TwigBundle, so the tests pass again.
```
There were 3 errors:
1) Symfony\Bundle\TwigBundle\Tests\CacheWarmingTest::testCacheIsProperlyWarmedWhenTemplatingIsAvailable
Symfony\Component\DependencyInjection\Exception\LogicException: Annotations cannot be enabled as the Doctrine Cache library is not installed.
2) Symfony\Bundle\TwigBundle\Tests\CacheWarmingTest::testCacheIsProperlyWarmedWhenTemplatingIsDisabled
Symfony\Component\DependencyInjection\Exception\LogicException: Annotations cannot be enabled as the Doctrine Cache library is not installed.
3) Symfony\Bundle\TwigBundle\Tests\NoTemplatingEntryTest::test
Symfony\Component\DependencyInjection\Exception\LogicException: Annotations cannot be enabled as the Doctrine Cache library is not installed.
```
Commits
-------
2dfde58851 Add Doctrine Cache to dev dependencies to fix failing unit tests.
This PR was merged into the 3.4 branch.
Discussion
----------
[SecurityBundle][Profiler] Give info about called security listeners in profiler
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #11134
| License | MIT
| Doc PR | n/a
Currently the profiler gives no info about security listeners (see fixed ticket), this displays each called listener with the time spent at calling it and its response if any.
![preview](https://image.prntscr.com/image/Wx-n-Ni_RQK5JGTdTZsdGw.png)
Commits
-------
369f19fcfd Give info about called security listeners in profiler
* 3.4:
[FrameworkBundle] removed doctrine/cache as a dependency
drop hard dependency on the Stopwatch component
Fix the conditional definition of the SymfonyTestsListener
[DI] Fix keys resolution in ResolveParameterPlaceHoldersPass
[FrameworkBundle] Fix colliding service ids
[FrameworkBundle] deprecated validator.mapping.cache.doctrine.apc
remove now useless condition
Lazy load security listeners
[EventDispatcher] Remove dead code in WrappedListener
[Process] Deprecate ProcessBuilder
Fix non-dumped voters in security panel
search case insensitive
[VarDumper] Cyclic searching dumps
[Yaml] Remove line number in deprecation notices
[SecurityBundle] Made 2 service aliases private
Automatically enable the routing annotation loader
[FrameworkBundle] KernelTestCase: deprecate not using KERNEL_CLASS
This PR was merged into the 3.4 branch.
Discussion
----------
[FrameworkBundle] drop hard dependency on the Stopwatch component
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | related to symfony/flex#14
| License | MIT
| Doc PR |
Commits
-------
8d70ca0ff4 drop hard dependency on the Stopwatch component
This PR was squashed before being merged into the 3.4 branch (closes#23131).
Discussion
----------
[FrameworkBundle] Remove dependency on Doctrine cache
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | yes
| BC breaks? | yes
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | related to symfony/flex#14
| License | MIT
| Doc PR | n/a
In our quest to remove hard dependencies, I propose to remove `doctrine/cache` from the default dependencies on the Framework bundle. That's possible now as we have PSR6 cache support in Symfony and because Doctrine cache is only used for the validator mapping cache.
The two other occurrences are for the serializer (already deprecated in 3.3) and for annotations, where we need to keep it, but as Doctrine annotations is already optional, that's not an issue.
Commits
-------
a4e336ea34 [FrameworkBundle] removed doctrine/cache as a dependency
b57895ccaf [FrameworkBundle] deprecated validator.mapping.cache.doctrine.apc
* 3.3:
Fix the conditional definition of the SymfonyTestsListener
[DI] Fix keys resolution in ResolveParameterPlaceHoldersPass
[EventDispatcher] Remove dead code in WrappedListener
Fix non-dumped voters in security panel
[Yaml] Remove line number in deprecation notices
[SecurityBundle] Made 2 service aliases private
This PR was squashed before being merged into the 2.7 branch (closes#22931).
Discussion
----------
SCA with Php Inspections (EA Extended): 2.7
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Static Code Analysis with Php Inspections (EA Extended): dead code and control flow tweaks.
Commits
-------
598ae56cc9 SCA with Php Inspections (EA Extended): 2.7
This PR was squashed before being merged into the 2.7 branch (closes#23120).
Discussion
----------
Remove deprecated each function
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR |
Replace the `each()` function which is deprecated in PHP 7.2 (https://wiki.php.net/rfc/deprecations_php_7_2#each)
Commits
-------
232caad876 Remove deprecated each function
This PR was merged into the 3.4 branch.
Discussion
----------
[FrameworkBundle] KernelTestCase: deprecate not using KERNEL_CLASS
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/22668#issuecomment-299875161
| License | MIT
| Doc PR | N/A
Commits
-------
d102fc08e4 [FrameworkBundle] KernelTestCase: deprecate not using KERNEL_CLASS
This PR was merged into the 2.8 branch.
Discussion
----------
#22839 - changed debug toolbar dump section to relative and use full window width
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22839
| License | MIT
My approach to fix#22839 - instead of adding min-width I have switched the section to fill the full available width:
![zrzut ekranu 2017-05-30 o 10 18 25](https://cloud.githubusercontent.com/assets/1044032/26574462/bf80b6dc-4521-11e7-96cc-bec0de075329.png)
Commits
-------
65297de3aa#22839 - changed debug toolbar dump section to relative and use full window width
This PR was merged into the 3.4 branch.
Discussion
----------
Automatically enable the routing annotation loader
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | yes <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | there's probably one but I didn't find it
| License | MIT
| Doc PR |
Thanks to fqcn services, most of the time, we don't need the SensioFrameworkExtraBundle to use `@Route`.
So I suggest to automatically enable it when annotations are enabled. This way we could simplify https://github.com/symfony/recipes/blob/master/symfony/framework-bundle/3.3/etc/routing.yaml#L5.
Note: I added priority support for routing loaders to make sure sensio loaders are executed before ours.
Commits
-------
c2f796fa15 Automatically enable the routing annotation loader
This PR was merged into the 2.7 branch.
Discussion
----------
[FrameworkBundle] Fix perf issue in CacheClearCommand::warmup()
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
On slow file systems (eg on Windows), I noticed that writing files without doing any changes just kills perf.
Limiting the depth also helps when the symfony/cache component is used (because it can store thousands of files in its cache pool directory structure, and iterating there is also a waste of *fs* time).
I choose the max depth by looking at where existing apps put their files and added one level more just in case.
Commits
-------
b58f060fda [FrameworkBundle] Fix perf issue in CacheClearCommand::warmup()
* 2.7:
bumped Symfony version to 2.7.30
Cache ipCheck
updated VERSION for 2.7.29
update CONTRIBUTORS for 2.7.29
updated CHANGELOG for 2.7.29
show unique inherited roles
This PR was merged into the 2.7 branch.
Discussion
----------
[SecurityBundle] Show unique Inherited roles in profile panel
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
When more than one assigned role reaches the same inherited role then it's duplicated in the "Inherited roles" list.
The changes in the test case show the unexpected result before fix it:
```console
There was 1 failure:
1) Symfony\Bundle\SecurityBundle\Tests\DataCollector\SecurityDataCollectorTest::testCollectAuthenticationTokenAndRoles with data set #4 (array('ROLE_ADMIN', 'ROLE_OPERATOR'), array('ROLE_ADMIN', 'ROLE_OPERATOR'), array('ROLE_USER', 'ROLE_ALLOWED_TO_SWITCH'))
Failed asserting that Array &0 (
0 => 'ROLE_USER'
1 => 'ROLE_ALLOWED_TO_SWITCH'
2 => 'ROLE_USER'
) is identical to Array &0 (
0 => 'ROLE_USER'
1 => 'ROLE_ALLOWED_TO_SWITCH'
)
```
Commits
-------
7061bfbf3a show unique inherited roles
* 3.4:
[TwigBridge] Fix namespaced classes
bumped Symfony version to 3.3.2
updated VERSION for 3.3.1
updated CHANGELOG for 3.3.1
[DependencyInjection] Fix named args support in ChildDefinition
[Cache] Fallback to positional when keyed results are broken
[HttpFoundation][FrameworkBundle] Revert "trusted proxies" BC break
[Cache] MemcachedAdapter not working with TagAwareAdapter
Remove closure-proxy leftovers
fix used class name in deprecation message
[DependencyInjection] Use more clear message when unused environment variables detected
[Form][Profiler] Fixes form collector triggering deprecations
mitigate BC break with empty trusted_proxies
[Profiler] Never wrap in code excerpts
[Form][FrameworkBundle] Remove non-existing arg for data_collector.form
explain that a role can be an instance of Role
[Cache] fix Redis scheme detection
Implement ServiceSubscriberInterface in optional cache warmers
Deprecate passing a concrete service in optional cache warmers
mix attr options between type-guess options and user options
* 3.3:
[TwigBridge] Fix namespaced classes
bumped Symfony version to 3.3.2
updated VERSION for 3.3.1
updated CHANGELOG for 3.3.1
[DependencyInjection] Fix named args support in ChildDefinition
[Cache] Fallback to positional when keyed results are broken
[HttpFoundation][FrameworkBundle] Revert "trusted proxies" BC break
[Cache] MemcachedAdapter not working with TagAwareAdapter
Remove closure-proxy leftovers
[DependencyInjection] Use more clear message when unused environment variables detected
[Form][Profiler] Fixes form collector triggering deprecations
mitigate BC break with empty trusted_proxies
[Profiler] Never wrap in code excerpts
[Form][FrameworkBundle] Remove non-existing arg for data_collector.form
explain that a role can be an instance of Role
[Cache] fix Redis scheme detection
mix attr options between type-guess options and user options
This PR was merged into the 3.3 branch.
Discussion
----------
[Form][Profiler] Fixes form collector triggering deprecations
| Q | A
| ------------- | ---
| Branch? | 3.3 <!-- see comment below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Since 3.3, if you inspect your logs when accessing the form profiler panel, you'll see some of these:
```sh
php.INFO: User Deprecated: The Symfony\Bundle\WebProfilerBundle\Twig\WebProfilerExtension::dumpValue() method is deprecated since version 3.2 and will be removed in 4.0.
[...] at /src/Symfony/Bundle/WebProfilerBundle/Twig/WebProfilerExtension.php:119
```
The [WebProfilerExtension](https://github.com/symfony/symfony/blob/master/src/Symfony/Bundle/WebProfilerBundle/Twig/WebProfilerExtension.php#L73) is still using a `ValueExporter` instance for BC reasons when the $value ins't an instance of `Data` and this BC layer will be removed in 4.0 (so it'll throw an exception/error when trying to use it with something else than a `Data` instance).
The issue is since #21638, collectors (including forms one) have been drastically simplified to leverage the "seamless usage of Data clones", which is great!... But there is a slightly different implementation between `Data::seek()` and [`Data::__get()`](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/VarDumper/Cloner/Data.php#L123-L130). There are probably good reasons for this, but it prevents from using classic Twig property access when the underlying data may be a scalar (`null`, `false`, ...).
I already spot that while working on the [Validator panel](https://github.com/symfony/symfony/pull/22554/files#diff-deac3c5ce4aa87243093dcd6a3f77a56R84). Perhaps there is a better solution, though.
Anyway, current `master` is currently broken, as it still tries to use the `ValueExporter`, which is already removed. And removing the BC layer in `WebProfilerExtension` isn't enough for now. It needs this fix.
BTW it also fixes rendering of the concerned inlined-dumps:
|Before|After|
|--|--|
|<img width="818" alt="screenshot 2017-06-03 a 13 35 25" src="https://cloud.githubusercontent.com/assets/2211145/26753222/01a692e6-4862-11e7-90d5-9cc9e4832648.PNG">|<img width="817" alt="screenshot 2017-06-03 a 13 35 47" src="https://cloud.githubusercontent.com/assets/2211145/26753224/090d5d6c-4862-11e7-87c1-73d5346f602c.PNG">|
Commits
-------
9de898d69f [Form][Profiler] Fixes form collector triggering deprecations
This PR was merged into the 3.3 branch.
Discussion
----------
[Profiler] Fix code excerpt wrapping
| Q | A
| ------------- | ---
| Branch? | 3.3 <!-- see comment below -->
| Bug fix? | yesish
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
|Before|After|
|--|--|
|<img width="1346" alt="screenshot 2017-05-30 a 19 09 03" src="https://cloud.githubusercontent.com/assets/2211145/26595449/b8c4302c-456b-11e7-83c4-3471f915437b.PNG">|<img width="1075" alt="screenshot 2017-05-30 a 19 09 35" src="https://cloud.githubusercontent.com/assets/2211145/26595450/b8c61e64-456b-11e7-8b33-bdbe2e90b160.PNG">|
However, I think my own preference for code excerpts would be to never wrap, at the risk of scrolling horizontally. 1024px is enough to read most of the code excerpt without scrolling, and it feels less messy (to me) when a line is too long. WDYT?
Commits
-------
6c87863a0e [Profiler] Never wrap in code excerpts
This PR was merged into the 3.3 branch.
Discussion
----------
[FrameworkBundle] mitigate BC break with empty trusted_proxies
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | kind of
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/22238#issuecomment-305932238
| License | MIT
| Doc PR |
Commits
-------
ff055ef7f3 mitigate BC break with empty trusted_proxies
* 3.4:
[Yaml] Clarify "incompatible key casting" deprecation message
minor #23043 add \ to PHP_VERSION_ID fixes#22650
[PhpUnitBridge] Fix detection of PHPUnit 5
Adding a new event subscriber that "parses" the _controller attribute in the FW
* 3.3:
[Yaml] Clarify "incompatible key casting" deprecation message
minor #23043 add \ to PHP_VERSION_ID fixes#22650
[PhpUnitBridge] Fix detection of PHPUnit 5
Adding a new event subscriber that "parses" the _controller attribute in the FW
This PR was merged into the 3.3 branch.
Discussion
----------
Parse the _controller format in sub-requests
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | possibly (edge case)
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22966
| License | MIT
| Doc PR | n/a
As mentioned on the issue (https://github.com/symfony/symfony/issues/22966#issuecomment-305289227), the new "controller service args" functionality relies on the `_controller` attribute to be in either the service format `App\Controller\Foo:bar` or at least the final parsed format `App\Controller\Foo::bar`. But when you make a sub-request with the `App:Foo:bar` format, the `ControllerResolver` correctly parses this, but the `_controller` request attribute will always contain the original `App:Foo:bar` format. That causes the `ServiceValueResolver` to fail.
The only way I can think to fix this - reliably - is to parse the `_controller` attribute in a listener. And this, works great! Notes:
A) There is a small chance for a BC break: if you were relying on the `_controller` old format in a `kernel.request` format in the framework, in a listener between the priority of 25 and 31 for sub-requests (because normal requests have `_controller` normalized during routing)... then you will see a behavior change.
B) We could load the `ControllerNameParser` lazily via a service locator.
C) We could deprecate calling the parser in the FW's `ControllerResolver`. Along with (B), I think it would (in 4.0) mean that the `ControllerNameParser` is not instantiated at runtime (except for sub-requests).
If someone can think of a different/better solution, please let me know!
Cheers!
Commits
-------
9578fd3eb6 Adding a new event subscriber that "parses" the _controller attribute in the FW
* 3.4:
Fix optional cache warmers are always instantiated whereas they should be lazy-loaded
add some \ on PHP_VERSION_ID for 2.8
[Di] Remove closure-proxy arguments
[PropertyInfo][DoctrineBridge] The bigint Doctrine's type must be converted to string
* 3.3:
Fix optional cache warmers are always instantiated whereas they should be lazy-loaded
add some \ on PHP_VERSION_ID for 2.8
[Di] Remove closure-proxy arguments
[PropertyInfo][DoctrineBridge] The bigint Doctrine's type must be converted to string
* 3.2:
Fix optional cache warmers are always instantiated whereas they should be lazy-loaded
add some \ on PHP_VERSION_ID for 2.8
[PropertyInfo][DoctrineBridge] The bigint Doctrine's type must be converted to string
* 2.8:
Fix optional cache warmers are always instantiated whereas they should be lazy-loaded
add some \ on PHP_VERSION_ID for 2.8
[PropertyInfo][DoctrineBridge] The bigint Doctrine's type must be converted to string
This PR was merged into the 3.3 branch.
Discussion
----------
[Di] Remove closure-proxy arguments
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
With #23008, we don't need this in core anymore.
Let's drop it now.
Technically that's a BC break, but for a feature that is very new, and still quite hidden.
Doing this now would save us from maintaining this code, and help reduce the overall complexity.
Basically reverts #20953
Commits
-------
57daadb [Di] Remove closure-proxy arguments
* 3.4: (31 commits)
Using FQ name for PHP_VERSION_ID
[EventDispatcher] Handle laziness internally instead of relying on ClosureProxyArgument
Fix CacheCollectorPass priority
[Form] Fix \IntlDateFormatter timezone parameter usage to bypass PHP bug #66323
[Routing] Allow GET requests to be redirected. Fixes#23004
[DI] Deal with inlined non-shared services
[Cache] Ignore missing annotations.php
[DI] Autowiring exception thrown when inlined service is removed
Improving deprecation message when hitting the "deprecated type" lookup, but an alias is available
Harden the debugging of Twig filters and functions
Fixing a bug where an autowiring exception was thrown even when that service was removed
Remove extra arg in call to TraceableAdapter::start()
Support unknown compiler log format
[Config] Allow empty globs
Fix decorating TagAware adapters in dev
[Profiler] Fix clicking on links inside toggle
[Profiler] Fix text selection on exception pages
bumped Symfony version to 3.3.1
updated VERSION for 3.3.0
updated CHANGELOG for 3.3.0
...
* 3.3: (31 commits)
Using FQ name for PHP_VERSION_ID
[EventDispatcher] Handle laziness internally instead of relying on ClosureProxyArgument
Fix CacheCollectorPass priority
[Form] Fix \IntlDateFormatter timezone parameter usage to bypass PHP bug #66323
[Routing] Allow GET requests to be redirected. Fixes#23004
[DI] Deal with inlined non-shared services
[Cache] Ignore missing annotations.php
[DI] Autowiring exception thrown when inlined service is removed
Improving deprecation message when hitting the "deprecated type" lookup, but an alias is available
Harden the debugging of Twig filters and functions
Fixing a bug where an autowiring exception was thrown even when that service was removed
Remove extra arg in call to TraceableAdapter::start()
Support unknown compiler log format
[Config] Allow empty globs
Fix decorating TagAware adapters in dev
[Profiler] Fix clicking on links inside toggle
[Profiler] Fix text selection on exception pages
bumped Symfony version to 3.3.1
updated VERSION for 3.3.0
updated CHANGELOG for 3.3.0
...
* 3.2:
Using FQ name for PHP_VERSION_ID
[Form] Fix \IntlDateFormatter timezone parameter usage to bypass PHP bug #66323
Harden the debugging of Twig filters and functions
bumped Symfony version to 3.2.10
updated VERSION for 3.2.9
updated CHANGELOG for 3.2.9
bumped Symfony version to 2.8.22
updated VERSION for 2.8.21
updated CHANGELOG for 2.8.21
bumped Symfony version to 2.7.29
updated VERSION for 2.7.28
update CONTRIBUTORS for 2.7.28
updated CHANGELOG for 2.7.28
* 2.8:
Using FQ name for PHP_VERSION_ID
[Form] Fix \IntlDateFormatter timezone parameter usage to bypass PHP bug #66323
Harden the debugging of Twig filters and functions
bumped Symfony version to 2.8.22
updated VERSION for 2.8.21
updated CHANGELOG for 2.8.21
bumped Symfony version to 2.7.29
updated VERSION for 2.7.28
update CONTRIBUTORS for 2.7.28
updated CHANGELOG for 2.7.28
* 2.7:
Using FQ name for PHP_VERSION_ID
[Form] Fix \IntlDateFormatter timezone parameter usage to bypass PHP bug #66323
Harden the debugging of Twig filters and functions
bumped Symfony version to 2.7.29
updated VERSION for 2.7.28
update CONTRIBUTORS for 2.7.28
updated CHANGELOG for 2.7.28
This PR was squashed before being merged into the 3.3 branch (closes#22968).
Discussion
----------
[Profiler] Fix text selection & click on file links on exception pages
| Q | A
| ------------- | ---
| Branch? | 3.3 <!-- see comment below -->
| Bug fix? | yes
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | #22957, #22978 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
I don't really know the purpose of this css rule here, but I admit it's quite frustrating not to be able to select something here.
This PR also prevents the following annoying behavior (selecting text collapses/uncollapses traces):
![mai-30-2017 18-26-29](https://cloud.githubusercontent.com/assets/2211145/26593977/3afbc510-4566-11e7-9114-8934ba6126a2.gif)
About the trick used, I think the browser support is safe enough: https://caniuse.com/#search=window.getSelection
EDIT: new commit added which allows to fix#22978
Commits
-------
8618399e42 [Profiler] Fix clicking on links inside toggle
ff6151b15f [Profiler] Fix text selection on exception pages
* 3.4:
[Console] ChoiceQuestion must have choices
[Filesystem] improve error handling in lock()
[FrameworkBundle][Console] Fix the override of a command registered by the kernel
* 3.3:
[Console] ChoiceQuestion must have choices
[Filesystem] improve error handling in lock()
[FrameworkBundle][Console] Fix the override of a command registered by the kernel
* 3.2:
[Console] ChoiceQuestion must have choices
[Filesystem] improve error handling in lock()
[FrameworkBundle][Console] Fix the override of a command registered by the kernel
* 2.8:
[Console] ChoiceQuestion must have choices
[Filesystem] improve error handling in lock()
[FrameworkBundle][Console] Fix the override of a command registered by the kernel
* 2.7:
[Console] ChoiceQuestion must have choices
[Filesystem] improve error handling in lock()
[FrameworkBundle][Console] Fix the override of a command registered by the kernel
* 3.4:
typo
Fixed options stub values display in form profiler
[Console] Fix tests
Make the simple exception pages match the new style
[Console] Fixed different behaviour of key and value user inputs in multiple choice question
Adjust PHPUnit class_alias check to also check for namespaced class
[Cache] Dont use pipelining with RedisCluster
[Yaml] fix colon without space deprecation
[Intl] Fix intl tests for PHP < 5.5.10
* 3.3:
typo
Fixed options stub values display in form profiler
[Console] Fix tests
Make the simple exception pages match the new style
[Console] Fixed different behaviour of key and value user inputs in multiple choice question
Adjust PHPUnit class_alias check to also check for namespaced class
[Cache] Dont use pipelining with RedisCluster
[Yaml] fix colon without space deprecation
[Intl] Fix intl tests for PHP < 5.5.10
This PR was merged into the 3.4 branch.
Discussion
----------
[3.4] Allow 4.* deps
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22756
| License | MIT
| Doc PR | -
This is implementing option 3 as described in #22756.
See #22769 for corresponding PR on 2.8: everything goes well and this allows catching a few more potential mistakes.
Commits
-------
c3e1646af8 [3.4] Allow 4.* deps
This PR was merged into the 3.2 branch.
Discussion
----------
[DI] Check for privates before shared services
| Q | A
| ------------- | ---
| Branch? | 3.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/22801#discussion_r117732213, https://github.com/symfony/symfony/pull/22801#discussion_r117732599
| License | MIT
| Doc PR | symfony/symfony-docs#... <!--highly recommended for new features-->
cc @stof
Commits
-------
4f683a9a5b [DI] Check for privates before shared services
* 3.4:
[DI] prepare for signature change in 4.0
[DI] Add missing deprecation on Extension::getClassesToCompile
[Lock] Re-add the Lock component in 3.4
[Routing] remove an unused routing fixture
[Yaml] fix multiline block handling
[WebProfilerBundle] Fix sub-requests display in time profiler panel
[FrameworkBundle] Handle project dir in cache:clear command
[WebServerBundle] Mark ServerCommand as internal
[DI] Fix autowire error for inlined services
Close PHP code in phpt file
[Profiler][VarDumper] Fix searchbar css when in toolbar
Prevent auto-registration of UserPasswordEncoderCommand
[Process] Fixed incorrectly escaping arguments on Windows when inheritEnvironmentVariables is set to false
avoid double blanks while rendering form attributes
use getProjectDir() when possible
[PhpUnitBridge] add a changelog file
[FrameworkBundle][Validator] Deprecate passing validator instances/aliases over using the service locator
* 3.3:
[DI] prepare for signature change in 4.0
[DI] Add missing deprecation on Extension::getClassesToCompile
[Routing] remove an unused routing fixture
[Yaml] fix multiline block handling
[WebProfilerBundle] Fix sub-requests display in time profiler panel
[FrameworkBundle] Handle project dir in cache:clear command
[WebServerBundle] Mark ServerCommand as internal
[DI] Fix autowire error for inlined services
Close PHP code in phpt file
[Profiler][VarDumper] Fix searchbar css when in toolbar
Prevent auto-registration of UserPasswordEncoderCommand
[Process] Fixed incorrectly escaping arguments on Windows when inheritEnvironmentVariables is set to false
avoid double blanks while rendering form attributes
use getProjectDir() when possible
[PhpUnitBridge] add a changelog file
[FrameworkBundle][Validator] Deprecate passing validator instances/aliases over using the service locator
This PR was merged into the 3.3 branch.
Discussion
----------
[FrameworkBundle][Validator] Deprecate passing validator instances/aliases over using the service locator
| Q | A
| ------------- | ---
| Branch? | 3.3 <!-- see comment below -->
| Bug fix? | no
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | yes <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/22800#issuecomment-302865630 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Commits
-------
df747ce [FrameworkBundle][Validator] Deprecate passing validator instances/aliases over using the service locator
This PR was merged into the 3.3 branch.
Discussion
----------
[SecurityBundle] Prevent auto-registration of UserPasswordEncoderCommand
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22855
| License | MIT
| Doc PR | n/a
Always registers the command as a service even if no encoders are configured so that it is not auto-registered via reflection.
Prevents an irrelevant deprecation when no encoders are configured and, if a day the per-convention command registration is removed, ensures that the command always exists (leading to an exception saying that you have no configured encoder, better than nothing).
ping @ogizanagi
Commits
-------
b39b35b Prevent auto-registration of UserPasswordEncoderCommand
This PR was merged into the 3.3 branch.
Discussion
----------
[Profiler][VarDumper] Fix searchbar css when in toolbar
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
Because css is hard (`.sf-toolbarreset *` has precedence since 4acec8973f moved the `toolbar.css.twig` inclusion from up to bottom):
|Before|After|
|--|--|
|<img width="291" alt="screenshot 2017-05-22 a 19 36 06" src="https://cloud.githubusercontent.com/assets/2211145/26321182/208780c0-3f26-11e7-89bb-7aa64f17c7b5.PNG">|<img width="280" alt="screenshot 2017-05-22 a 19 36 27" src="https://cloud.githubusercontent.com/assets/2211145/26321188/248ed0ce-3f26-11e7-852a-40968fba2e9f.PNG">|
Commits
-------
98b3002 [Profiler][VarDumper] Fix searchbar css when in toolbar
This PR was merged into the 3.3 branch.
Discussion
----------
use getProjectDir() when possible
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | continues #22315
| License | MIT
| Doc PR |
Commits
-------
a8e298a66c use getProjectDir() when possible
This PR was merged into the 3.3 branch.
Discussion
----------
[FrameworkBundle][Translation] fix docblock position
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22822
| License | MIT
| Doc PR |
The `$defaultLocale` argument is present in the `Translator` class of
the FrameworkBundle, but is not part of the Translation component.
Commits
-------
0829964 fix docblock position
This PR was merged into the 3.3 branch.
Discussion
----------
[DI] Remove dead service_container checks
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!--highly recommended for new features-->
Since #21627
Commits
-------
9a8ea93 [DI] Remove dead service_container checks
This PR was merged into the 3.4 branch.
Discussion
----------
[FrameworkBundle] add forward compatibility layer for FrameworkBundle
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Commits
-------
9f14d06 [FrameworkBundle] add forward compatibility layer when using FrameworkBundle in version 3.4 with DependencyInjection component in version 4.0
* 3.4:
bug #22814 [FrameworkBundle] FC with EventDispatcher 4.0 (xabbuh)
[PhpUnitBridge] remove unused use statement
do not used deprecated validator test case class
do not mock a deprecated interface
[DI] Added missing deprecation in changelog
[Ldap] add a changelog file
[Security][Serializer][DI] Add new arguments typehints in preparation for 4.0
[MonologBridge] Fix the Monlog ServerLogHandler from Hanging on Windows
[DependencyInjection] Fix dumping of RewindableGenerator with empty IteratorArgument
[DI][Serializer] Fix missing de(normalizer|coder) autoconfig
Use 0.0.0.0 as the server log host default.
* 3.3:
[PhpUnitBridge] remove unused use statement
do not mock a deprecated interface
[DI] Added missing deprecation in changelog
[Ldap] add a changelog file
[Security][Serializer][DI] Add new arguments typehints in preparation for 4.0
[MonologBridge] Fix the Monlog ServerLogHandler from Hanging on Windows
[DependencyInjection] Fix dumping of RewindableGenerator with empty IteratorArgument
[DI][Serializer] Fix missing de(normalizer|coder) autoconfig
Use 0.0.0.0 as the server log host default.
This PR was merged into the 3.3 branch.
Discussion
----------
[DI][Serializer] Fix missing de(normalizer|coder) autoconfig
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes(ish)
| New feature? | no (at least complete the 3.3 feature)
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
Just migrating an app to `3.3.0-RC1`, I get surprised it wasn't already registered :)
Commits
-------
3c3a276 [DI][Serializer] Fix missing de(normalizer|coder) autoconfig
This PR was merged into the 4.0-dev branch.
Discussion
----------
[FrameworkBundle] FC with EventDispatcher 4.0
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/22796#issuecomment-302875580
| License | MIT
| Doc PR |
Commits
-------
b7c76f7 [FrameworkBundle] FC with EventDispatcher 4.0
This PR was merged into the 4.0-dev branch.
Discussion
----------
[FrameworkBundle] FC with EventDispatcher 4.0
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/22796#issuecomment-302875580
| License | MIT
| Doc PR |
Commits
-------
b7c76f7 [FrameworkBundle] FC with EventDispatcher 4.0
This PR was squashed before being merged into the 4.0-dev branch (closes#22779).
Discussion
----------
[4.0][BC Break] Removed BC layers for ControllerResolver::getArguments()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | yes
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | ~
| License | MIT
| Doc PR | ~
Removes the Backwards Compatibility layer for the `ControllerResolver` that depends on the `ArgumentValueResolver`. ~~There's still 1 bit left in the `HttpKernel`, but I don't quite know how this is solved in the best way:~~
```php
public function __construct(EventDispatcherInterface $dispatcher, ControllerResolverInterface $resolver, RequestStack $requestStack = null, ArgumentResolverInterface $argumentResolver = null)
{
$this->dispatcher = $dispatcher;
$this->resolver = $resolver;
$this->requestStack = $requestStack ?: new RequestStack();
$this->argumentResolver = $argumentResolver;
if (null === $this->argumentResolver) {
@trigger_error(sprintf('As of 3.1 an %s is used to resolve arguments. In 4.0 the $argumentResolver becomes the %s if no other is provided instead of using the $resolver argument.', ArgumentResolverInterface::class, ArgumentResolver::class), E_USER_DEPRECATED);
// fallback in case of deprecations
$this->argumentResolver = $resolver;
}
}
```
~~The 4th argument is now mandatory, but I can't make it mandatory without switching it with the request stack.~~
- ~~I can make both mandatory~~
- ~~I can make it `?RequestStack`~~
- ~~I can switch the arguments~~
~~Each of those area a BC break but for the request stack or the switch, there is no BC layer yet (could be done in 3.4).~~
Commits
-------
64ac6e5 [4.0][BC Break] Removed BC layers for ControllerResolver::getArguments()
This PR was merged into the 3.3 branch.
Discussion
----------
Use 0.0.0.0 as the server log command host default.
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | -
| Fixed tickets | -
| License | MIT
This fixes the `server:log` command on Windows when run with default settings. The current setting `0` has no meaning on Windows, and `0.0.0.0` is the standard "listen on all addresses/interfaces", so should be the most compatible. It works on both Linux and Windows for me this way.
I mentioned this in another PR where the logger config has the same issue on Windows:
https://github.com/symfony/symfony-standard/pull/1077
Commits
-------
3fcc810dd7 Use 0.0.0.0 as the server log host default.
* 3.4:
typo
CI fixes
Improved how profiler errors are dispalyed on small screens
bumped Symfony version to 3.3.0
updated VERSION for 3.3.0-RC1
updated CHANGELOG for 3.3.0-RC1
* 3.3:
typo
CI fixes
Improved how profiler errors are dispalyed on small screens
bumped Symfony version to 3.3.0
updated VERSION for 3.3.0-RC1
updated CHANGELOG for 3.3.0-RC1
* 3.2:
removed unneeded annotation in tests
[Intl][Form] Update tests, TimeZoneTransformer, and DateTimeToLocalizedStringTransformer for the GMT and UTC split in ICU
remove Security deps from the require section
[Intl] Update ICU data to 59.1
This PR was merged into the 3.3-dev branch.
Discussion
----------
[TwigBundle] service workflow.twig_extension should stay public
| Q | A
| ------------- | ---
| Branch? | master (3.3)
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
While it's not really required for this service to be public AFAIK, it was not made private when introducing it in 3.2. Which means it should stay public in upper branches. But [since we now default to `public: false`](https://github.com/symfony/symfony/pull/22615) in every service config file, it's currently private in 3.3.
I had a quick look on commits merged after this PR and didn't find any other similar case.
Commits
-------
5d07c6aa76 [TwigBundle] service workflow.twig_extension should stay public
* 3.2:
[Console] Do not duplicate Helper::strlen() code
[FrameworkBundle] Adding the extension XML
[Form] Minor: Fix comment in ChoiceType
[FrameworkBundle] AbstractConfigCommand: do not try registering bundles twice
fixed CS
fixed CS
[DI] Fix PhpDumper blank lines around namespace
fixed CS
[Workflow] fix use directives
[Workflow] Move twig extension registration to twig bundle
Filesystem: annotate the one network test with a "network" group.
[DependencyInjection] Don't store default deprecation template in every service definition instance
* 2.8:
[Console] Do not duplicate Helper::strlen() code
[FrameworkBundle] Adding the extension XML
[Form] Minor: Fix comment in ChoiceType
[FrameworkBundle] AbstractConfigCommand: do not try registering bundles twice
* 2.7:
[Console] Do not duplicate Helper::strlen() code
[FrameworkBundle] Adding the extension XML
[Form] Minor: Fix comment in ChoiceType
[FrameworkBundle] AbstractConfigCommand: do not try registering bundles twice
This PR was merged into the 2.7 branch.
Discussion
----------
[FrameworkBundle] AbstractConfigCommand: do not try registering bundles twice
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/recipes/issues/46
| License | MIT
| Doc PR | N/A
As spotted in https://github.com/symfony/recipes/issues/46, there is no reason to call `registerBundles` on the kernel instance, as it's already booted. So we just have to use `getBundles` instead and `registerBundles` can be implemented in a non-rewindable way, as done with flex.
Commits
-------
040edfec4a [FrameworkBundle] AbstractConfigCommand: do not try registering bundles twice
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle] Fix "Locale class not found" in AboutCommand
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Found testing http://fabien.potencier.org/symfony4-demo.html with docker `php:7.1`
Commits
-------
0269f9d422 [FrameworkBundle] Fix "Locale class not found" in AboutCommand
This PR was merged into the 3.2 branch.
Discussion
----------
[Workflow] Move twig extension registration to twig bundle
| Q | A
| ------------- | ---
| Branch? | 3.2
| Bug fix? | not really
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
It's probably very late, but I think the twig extension registration is supposed to be done from the `TwigBundle` rather than the `FrameworkBundle`. Fortunately, it doesn't cause any issue currently when using the framework bundle and the workflow component without twig, because it only creates a `workflow.twig_extension` service you'll probably never call, and the `twig.extension` tag is never processed. But still, creates a useless service that cannot be called (and is not removed because it's public).
So this PR aims for consistency over other twig extensions registration, and removing this service when not using twig.
It isn't a BC break to me, as you usually already use the `TwigBundle` for other extensions.
Commits
-------
3fc80d10ef [Workflow] Move twig extension registration to twig bundle
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle] KernelTestCase: allow to provide the kernel class with a var
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | yes, but must-have for the new project structure when using flex
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22661
| License | MIT
| Doc PR | todo in https://symfony.com/doc/current/testing.html#your-first-functional-test
So, when using flex, the new `phpunit.xml.dist` will be:
```diff
<?xml version="1.0" encoding="UTF-8"?>
<!-- https://phpunit.de/manual/current/en/appendixes.configuration.html -->
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/6.1/phpunit.xsd"
backupGlobals="false"
colors="true"
bootstrap="vendor/autoload.php"
>
<php>
<ini name="error_reporting" value="-1" />
- <server name="KERNEL_DIR" value="etc/" />
+ <server name="KERNEL_CLASS" value="App\Kernel" />
</php>
<testsuites>
<testsuite name="Project Test Suite">
<directory>tests/</directory>
</testsuite>
</testsuites>
</phpunit>
```
As it may cause issues when refactoring, I added a `class_exists` check with an appropriate exception to indicate the class is either not found or not autoloadable.
Commits
-------
4f68912552 [FrameworkBundle] KernelTestCase: allow to provide the kernel class with a var
* 2.8:
fixed CS
[DI] Fix PhpDumper blank lines around namespace
fixed CS
Filesystem: annotate the one network test with a "network" group.
[DependencyInjection] Don't store default deprecation template in every service definition instance
This PR was merged into the 3.3-dev branch.
Discussion
----------
Improved the stack traces that don't contain a function
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
When a trace doesn't have a method/function associated, we display `n/a` and the file path below it. This usually happens in the first line of the stack traces. I don't think this looks OK, so I'm proposing to change it as follows:
### Before
![before-exception](https://cloud.githubusercontent.com/assets/73419/25782450/ae521cc6-334b-11e7-9e22-b31342667f6c.png)
### After
![after-exception](https://cloud.githubusercontent.com/assets/73419/25782451/b1b9957e-334b-11e7-812f-8c24ab8872df.png)
Commits
-------
9457558457 Improved the stack traces that don't contain a function
This PR was merged into the 3.3-dev branch.
Discussion
----------
[WebLink][TwigBundle] Fix registration of the twig extension
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | See http://symfony.com/blog/new-in-symfony-3-3-weblink-component comments
| License | MIT
| Doc PR | N/A
BTW it is the only extension not using a classic service definition and adding the tag using the `Symfony\Bundle\TwigBundle\DependencyInjection\Compiler\ExtensionPass` class.
(Fabbot failure fixed in https://github.com/symfony/symfony/pull/22640)
Commits
-------
3d8a5646e7 [WebLink][TwigBundle] Fix registration of the twig extension
This PR was merged into the 3.3-dev branch.
Discussion
----------
Make the exception pages work when the WebProfilerBundle is not installed
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22631
| License | MIT
| Doc PR | -
Commits
-------
98353b0032 Make the exception pages work when the WebProfilerBundle is not installed
This PR was merged into the 3.3-dev branch.
Discussion
----------
Add some missing docs for the web server bundle
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
This is an alternative to #22471
Commits
-------
987a6819d2 added some missing docs for the web server bundle
This PR was merged into the 3.3-dev branch.
Discussion
----------
[DX][FrameworkBundle] Show private aliases in debug:container
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/16388https://github.com/Haehnchen/idea-php-symfony2-plugin/issues/618
| License | MIT
| Doc PR | n/a
By building and compiling the container without `TYPE_REMOVING` passes, private aliases are available (shown when `--show-private` is passed). The ContainerBuilderDebugDumpPass now makes use of the ConfigCache component, removing the need for clearing the cache to get the debug:container output up to date (in sync with latest config).
Config
-------
```yaml
services:
AppBundle\Foo:
public: false
foo_consumer1:
class: AppBundle\Foo
arguments: [ '@AppBundle\Foo' ]
foo_consumer2:
class: AppBundle\Foo
arguments: [ '@AppBundle\Foo' ]
foo_alias:
alias: AppBundle\Foo
foo_private_alias:
public: false
alias: AppBundle\Foo
```
Before
-------
![before](http://image.prntscr.com/image/2a69485a4a764316a90260b4e3dfc2a2.png)
After
------
![after](http://image.prntscr.com/image/ea42daa0e5c94841a28dd256450dc8ef.png)
Commits
-------
883723ef53 Show private aliases in debug:container
This PR was merged into the 3.3-dev branch.
Discussion
----------
[Security] add Request type json check in json_login
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no, unreleased feature
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR | -
follow up to https://github.com/symfony/symfony/pull/22425 to limit the `UsernamePasswordJsonAuthenticationListener` to only requests with appropriate JSON content type.
I am not entirely happy with this implementation but mostly because Symfony out of the box only provides very limited content type negotiation. I guess anyone that wants to tweak the content negotiation will simply need to ensure the Request::$format is set accordingly before the code is triggered.
Commits
-------
045a36b303 add Request type json check in json_login
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle] Restore 3.2-like behavior for FormPass, to help BC with Sonata
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
I tried updating a Sonata project to 3.3, and found it broken.
The issue is that Sonata uses the constructor arguments of the `form.extension` to create its own `form.extension` service - but borrows its first args from the Symfony one.
Here is the form pass doing that:
https://github.com/sonata-project/SonataCoreBundle/blob/3.x/DependencyInjection/Compiler/FormFactoryCompilerPass.php
And the implementation of the form extension:
https://github.com/sonata-project/SonataCoreBundle/blob/3.x/DependencyInjection/SonataCoreExtension.php
Question: is this covered by the BC policy? It shouldn't to me, because that would prevent *any* service reconfiguration.
Thus, I'm proposing the attached patch, which basically reverts the deprecated `FormPass` in FrameworkBundle to its 3.2 state.
I added a check to the new `FormPass` in the Form component so that it doesn't overwrite such compatibility configurations.
See for corresponding fix on https://github.com/sonata-project/SonataCoreBundle/pull/399
Commits
-------
c97b08e6c0 [FrameworkBundle] Restore 3.2-like behavior for FormPass, to help BC with Sonata
This PR was merged into the 3.3-dev branch.
Discussion
----------
[SecurityBundle] Enhance FirewallContext::getListeners()
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/20417#discussion_r91704023, https://github.com/symfony/symfony/pull/20417#discussion_r91704145
| License | MIT
| Doc PR | symfony/symfony-docs#... <!--highly recommended for new features-->
I think @stof is right.. and the fact we can do this on master currently without the hassle.
cc @chalasr
Commits
-------
ba650783f5 [SecurityBundle] Enhance FirewallContext::getListeners()
* 3.2:
Fixed the flickering when loading complex profiler panels
[Console] Fix bar width with multilines ProgressBar's format
[DI] Add missing check in PhpDumper
[Serializer] XmlEncoder: fix negative int and large numbers handling
[Console] Fix dispatching throwables from ConsoleEvents::COMMAND
* 2.8:
Fixed the flickering when loading complex profiler panels
[DI] Add missing check in PhpDumper
[Serializer] XmlEncoder: fix negative int and large numbers handling
[Console] Fix dispatching throwables from ConsoleEvents::COMMAND
This PR was merged into the 3.3-dev branch.
Discussion
----------
[Console] Review console.ERROR related behavior
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This PR is a follow up of #18140 that I wanted to do since a few weeks.
It enhances this work with fixes and behavior changes.
It embeds #22435 and resolves issues like the one described in #20808.
- makes ConsoleErrorEvent *not* extend the deprecated ConsoleExceptionEvent
- replace ConsoleErrorEvent::markErrorAsHandled by ConsoleErrorEvent::setExitCode
- triggers the deprecation in a more appropriate moment
- renames ExceptionListener to ErrorListener
- tweaks the behavior in relation to #22435
Commits
-------
a7c67c9ab2 [Console] Review console.ERROR related behavior
This PR was merged into the 3.3-dev branch.
Discussion
----------
[Cache] Keep only hit/miss (not values) in TraceableAdapter/Cache
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Right now, TraceableAdapter and TraceableCache both keep all fetched values.
This exhaustive reporting is too much data gathering to me.
Here is a PR that keeps only true/false for each hit/miss + all corresponding keys.
That can still be a lot of data (one item per fetched key) - but a bit better.
Should we go further in stats-only gathering? Or should we *not* do this and keep collecting *all* the values?
The PR also fixes "Traversable" handling.
ping @Nyholm
The profiler panel still works (although breaking lines in the middle of words is strange, but this is the profiler's CSS, nothing special to this specific case).
![capture du 2017-04-19 11-40-13](https://cloud.githubusercontent.com/assets/243674/25173586/f9615dd6-24f4-11e7-8d6f-36fb2437c3b6.png)
Commits
-------
0c73c5d [Cache] Keep only hit/miss (not values) in TraceableAdapter/Cache
This PR was merged into the 3.3-dev branch.
Discussion
----------
[DI] Allow service subscribers to leverage autowiring to know where their locator should be injected
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
e407b3d42e [DI] Allow service subscribers to leverage autowiring to know where the locator should be injected
This PR was merged into the 3.3-dev branch.
Discussion
----------
[Security] Fix json_login default success/failure handling
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no (master only)
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22483
| License | MIT
| Doc PR | n/a
This makes the `json_login` listener default configuration stateless oriented by:
- Not using the default (redirect based) failure handler, it returns a 401 (json) response containing the failure reason instead
- Not using the default (redirect based) success handler, just let the original request continue instead (reaching the targeted resource without being redirected).
- Setting `require_previous_session` to `false` by default (I have to set it on `form-login` each time I want it to be stateless)
- Removing the options related to redirections (`default_target_path`, `login_path`, ...) from the listener factory, if one wants redirections then one has to write its own handlers, not the inverse
Commits
-------
9749618ff5 Fix json_login default success/failure handling
This PR was squashed before being merged into the 3.3-dev branch (closes#22234).
Discussion
----------
[DI] Introducing autoconfigure: automatic _instanceof configuration
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes (mostly, a continuation of a new feature)
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/issues/7538
This is a proposal to allow the user to opt into some automatic `_instanceof` config. Suppose I want to auto-tag all of my voters and event subscribers
```yml
# current
services:
_defaults:
autowire: true
_instanceof:
Symfony\Component\Security\Core\Authorization\Voter\VoterInterface:
tags: [security.voter]
Symfony\Component\EventDispatcher\EventSubscriberInterface:
tags: [kernel.event_subscriber]
# services using the above tags
AppBundle\Security\PostVoter: ~
AppBundle\EventListener\CheckRequirementsSubscriber: ~
```
If I'm registering a service with a class that implements `VoterInterface`, when would I ever *not* want that to be tagged with `security.voter`? Here's the proposed code:
```yml
# proposed
services:
_defaults:
autowire: true
autoconfigure: true
# services using the auto_configure_instanceof functionality
AppBundle\Security\PostVoter: ~
AppBundle\EventListener\CheckRequirementsSubscriber: ~
```
The user must opt into this and it only applies locally to this configuration file. It works because each enabled bundle would have the opportunity to add one or more "automatic instanceof" definitions - e.g. SecurityBundle would add the `security.voter` instanceof config, FrameworkBundle would add the `kernel.event_subscriber` instanceof config, etc.
For another example, you can check out the proposed changes to `symfony-demo` - symfony/symfony-demo#483 - the `_instanceof` section is pretty heavy: 81694ac21e/app/config/services.yml (L20)
Thanks!
Commits
-------
18627bf9f6 [DI] Introducing autoconfigure: automatic _instanceof configuration
This PR was merged into the 3.3-dev branch.
Discussion
----------
Persist app bootstrapping logs for logger datacollector
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | yes
| BC breaks? | ?
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #21405
| License | MIT
Logs generated during the container build are catched by the BufferingLogger with a special flag.
They are persist by the LoggerDataCollector and are available in the logger profiler.
In the profiler toolbar, the "container build" logs increment the current logs counter (even if the container was previously built).
<img width="540" alt="capture d ecran 2017-02-01 a 20 56 40" src="https://cloud.githubusercontent.com/assets/1017746/22523826/0bc12e4a-e8c1-11e6-830f-7f6238ea7423.png">
<img width="1022" alt="capture d ecran 2017-02-01 a 20 57 55" src="https://cloud.githubusercontent.com/assets/1017746/22523859/2c48a698-e8c1-11e6-9bdb-d85f3e692938.png">
The BufferingLogger now require the cachePath and the filesystem to persist a (unique) container build logs.
If the current workflow is ok, I will update the test coverage (actually they fail). Maybe we can display the appDevDebugProjectContainerCompiler.log content in that logger profile.
Commits
-------
2fd18b5503 [VarDumper] Fine tune dumping log messages
ce3ef6a96e Persist app bootstrapping logs for logger datacollector
The conflict rule already forbids installing releases before 3.3 of the
Asset component. This will bring the constraint in the `require-dev`
section inline with the conflict rule.
* 3.2:
Make .travis.yml more readable
Fold Travis CI output by component
[VarDumper] Minor tweaks to html/css dumps
Add trhows PHPDoc in Application::run
[Debug] Set exit status to 255 on error
[HttpFoundation] Store IANA's RNG files in the repository
[PropertyInfo] Remove a useless call to count() in SerializerExtractor
[PropertyInfo] Prevent returning int values in some cases.
[HttpFoundation] Fix getClientIp @return docblock
Add @throws phpdoc
unify PHPUnit config files
This PR was squashed before being merged into the 3.3-dev branch (closes#22425).
Discussion
----------
[Security] Allow to set a check_path on json_login listener
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no, master only
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #21948, ~~#22423~~
| License | MIT
| Doc PR | n/a
The listener should allow to restrict authentication to a given check_path, as stated in the docs http://symfony.com/doc/master/security/json_login_setup.html
Commits
-------
9f7eb618a4 [Security] Allow to set a check_path on json_login listener
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle][Workflow] Deprecate the default type of a workflow
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
---
Before this patch, the default type is "workflow". Most of the time a
"state_machine" is better because it's simpler and it involves less
knowledge to be able to use it.
So this patch deprecate a missing type in Symfony 3.3. And In Symfony
4.0 the default value will become "state_machine".
Commits
-------
004751c [FrameworkBundle][Workflow] Deprecate the default type of a workflow
This PR was squashed before being merged into the 3.3-dev branch (closes#22420).
Discussion
----------
[DI] Make tagged abstract services throw earlier
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
As spotted by @stof in https://github.com/symfony/symfony/pull/22388#issuecomment-293565243, skipping abstract tagged services removes an opportunity to report config mistakes to users.
Instead of skipping them, let's throw as done before (thus reverting #22039, ping @chalasr).
I made `$container->findTaggedServiceIds()` accept a 2nd arg to make this more systematic.
To keep the possibility to have abstract tagged services *for the purpose of tag inheritance*, `ResolveTagsInheritancePass` now resets their tags.
Commits
-------
388e4b3389 [DI] Make tagged abstract services throw earlier
cd06c1297b Revert "minor #22039 Skip abstract definitions in compiler passes (chalasr)"
Before this patch, the default type is "workflow". Most of the time a
"state_machine" is better because it's simpler and it involves less
knowledge to be able to use it.
So this patch deprecate a missing type in Symfony 3.3. And In Symfony
4.0 the default value will become "state_machine".
* 3.2:
[2.8] Prevent double registrations related to tag priorities
Prevent double registrations related to tag priorities
[3.2] Prevent double registrations related to tag priorities
This PR was merged into the 2.8 branch.
Discussion
----------
[2.8] Prevent double registrations related to tag priorities
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
#22396 on 2.8
Commits
-------
2be5821743 [2.8] Prevent double registrations related to tag priorities
This PR was merged into the 2.7 branch.
Discussion
----------
Prevent double registrations related to tag priorities
| Q | A
| ------------- | ---
| Branch? | 2.7
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
The current logic is inconsistent, and allows the same id to be used several times. This makes the first explicit priority to always win.
Commits
-------
6764dcdf39 Prevent double registrations related to tag priorities
This PR was merged into the 3.3-dev branch.
Discussion
----------
added a more specialized exception for a better error message
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes/no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
When trying to load a resource, it is very interesting to understand why a resource cannot be loaded. Especially when you get `Cannot load resource "../src/Controller/".`... when the real error is that annotation support is disabled. This PR adds more information in that case.
Commits
-------
aeb9bffa8f added a more specialized exception for a better error message
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle] Use findDefinition() instead of getDefinition() on aliases
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
The services for which `has()` is called might be aliases at this point so `getDefinition()` gives an exception, I ran into by executing this pass but not the removing ones (skipping ReplaceAliasByActualDefinitionPass) while working on https://github.com/symfony/symfony/issues/16388. Let's make it safe to use independently.
Commits
-------
41f3d1f166 Use findDefinition() instead of getDefinition() after calling has()
This PR was squashed before being merged into the 3.3-dev branch (closes#22344).
Discussion
----------
[DX] [TwigBundle] Improve default expand states of exception template
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass? | yes
| Fixed tickets | #22334
| License | MIT
As discussed in #22334 this PR changes the default exception template to more intelligently decide which call stack to initially expand:
- All exceptions are scanned for user code, ignoring the front controller and callbacks
- Only exceptions containing user code are expanded
- If no user code is found the first exception is expanded
Commits
-------
df25691250 [DX] [TwigBundle] Improve default expand states of exception template
This PR was merged into the 3.3-dev branch.
Discussion
----------
[HttpKernel et al.] Move DataCollector::cloneVar() to lateCollect()
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22166
| License | MIT
| Doc PR | -
<!--
- Bug fixes must be submitted against the lowest branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
- Please fill in this template according to the PR you're about to submit.
- Replace this comment by a description of what your PR is solving.
-->
Commits
-------
f83f971c3f [HttpKernel et al.] Move DataCollector::cloneVar() to lateCollect()
This PR was merged into the 3.3-dev branch.
Discussion
----------
[HttpKernel][FrameworkBundle] Dump container logs in Kernel, to have them also on errors
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Inspecting container failures without the logs is hard, let's have them at hand. This should not be the responsibility of a compiler pass.
Commits
-------
a8b83340bb [HttpKernel][FrameworkBundle] Dump container logs in Kernel, to have them also on errors
This PR was merged into the 3.3-dev branch.
Discussion
----------
[BC BREAK][DI] Always autowire "by id" instead of using reflection against all existing services
| Q | A
| ------------- | ---
| Branch? | 3.3
| Bug fix? | no
| New feature? | yes
| BC breaks? | yes - compile time only
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
(patch best reviewed [ignoring whitespaces](https://github.com/symfony/symfony/pull/22295/files?w=1).)
"By-id" autowiring, as introduced in #22060 is free from all the issues that "by-type" autowiring has:
- it has no magic and requires explicit type<>id matching (*vs* using reflection on all services to cherry-pick *the* one that matches some type-hint *at that time*, which is fragile)
- it is free from any ambiguities (*vs* the Damocles' sword of breaking config just by enabling some unrelated bundle)
- it is easily introspected: just look at DI config files (*vs* inspecting the type-hierarchy of all services + their type-hints)
- ~~it is side-effect free, thus plain predictable (*vs* auto-registration of discovered types as services)~~
- it plays nice with deprecated services or classes (see #22282)
- *etc.*
Another consideration is that any "by-type" autowired configuration is either broken (because of future ambiguities) - or equivalent to a "by-id" configuration (because resolving ambiguities *means* adding explicit type<>id mappings.) For theoreticians, we could say that "by-id" autowiring is the asymptotic limit of "by-type" autowiring :-)
For all these reasons - and also because it reduces the complexity of the code base - I propose to change the behavior and only support "by-id" autowiring in 3.3. This will break some configurations relying on "by-type" autowiring. Yet the break will only happen at compile-time, which means this won't *silently* break any apps. For all core Symfony services, they will work out of the box thanks to #22098 *et al.* For the remaining services, fixing ones config should be pretty straightforward: just follow the suggestions provided by the exception messages. If they are fine to you, you'll end up with the exact same config in the end. And maybe you'll spot issues that were hidden previously.
Commits
-------
cc5e582dcf [BC BREAK][DI] Always autowire "by id" instead of using reflection against all existing services
This PR was merged into the 3.3-dev branch.
Discussion
----------
[WebProfiler] Fix race condition in fast Ajax requests
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22297
| License | MIT
Patch `startAjaxRequest` and `finishAjaxRequest` functions to absolute noop in case the debug toolbar itself is not loaded yet, and spool historic requests after the toolbar is loaded.
Commits
-------
538a59254f [WebProfiler] Fix race condition in fast Ajax requests
* 3.2:
bumped Symfony version to 3.2.8
updated VERSION for 3.2.7
updated CHANGELOG for 3.2.7
Fixes#22264 - add support for Chrome headless, see also Seldaek/monolog#966
[Workflow] update documentation URL in readme
bumped Symfony version to 2.8.20
updated VERSION for 2.8.19
updated CHANGELOG for 2.8.19
Dont call sprintf() when no placeholders are used
* 2.8:
Fixes#22264 - add support for Chrome headless, see also Seldaek/monolog#966
bumped Symfony version to 2.8.20
updated VERSION for 2.8.19
updated CHANGELOG for 2.8.19
Dont call sprintf() when no placeholders are used
Patch startAjaxRequest and finishAjaxRequest functions to absolute noop
in case the debug toolbar itself is not loaded yet, and spool historic
requests after the toolbar is loaded.
Fixes#22297
This PR was merged into the 3.3-dev branch.
Discussion
----------
[Security] Use IteratorArgument for voters
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| License | MIT
Use an IteratorArgument for injecting voters into the AccessDecisionManager.
Commits
-------
4ec80b1ae8 Use IteratorArgument for voters
* 3.2:
[FrameworkBundle] Update console fixtures after #22217
Allow Upper Case property names
fix some risky tests
bumped Symfony version to 2.7.27
updated VERSION for 2.7.26
update CONTRIBUTORS for 2.7.26
updated CHANGELOG for 2.7.26
This PR was squashed before being merged into the 2.8 branch (closes#22278).
Discussion
----------
[FrameworkBundle] Update console fixtures after #22217
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes (regression from #22217)
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/22217#issuecomment-291497513
| License | MIT
| Doc PR | symfony/symfony-docs#... <!--highly recommended for new features-->
cc @fabpot
Sorry for the inconvenience :)
Commits
-------
6e1cee6 [FrameworkBundle] Update console fixtures after #22217
* 3.2:
[DI] Autowiring and factories are incompatible with each others
[DI] Don't use auto-registered services to populate type-candidates
Lighten tests output by removing composer suggestions
support nullable array or collection
Complete the injection of the expression in all syntax errors
CS: Remove invisible chars
Disable resource tracking if the config component is missing
[EventDispatcher] Remove unneded count()
Fix tests expecting a valid date
Avoid forcing to define the choices_as_values option when using choice_loader
add expression text to SyntaxError
[Console] Fix table cell styling
[Console] Revised exception rendering
Fix @param in PHPDoc
[WebProfilerBundle] Normalize whitespace in exceptions passed in headers
Disable color support detection for tests
[Form] Improve the exceptions when trying to get the data in a PRE_SET_DATA listener and the data has not already been set
* 2.8:
[DI] Autowiring and factories are incompatible with each others
[DI] Don't use auto-registered services to populate type-candidates
Lighten tests output by removing composer suggestions
support nullable array or collection
Complete the injection of the expression in all syntax errors
CS: Remove invisible chars
Disable resource tracking if the config component is missing
[EventDispatcher] Remove unneded count()
Fix tests expecting a valid date
Avoid forcing to define the choices_as_values option when using choice_loader
add expression text to SyntaxError
[Console] Fix table cell styling
[Console] Revised exception rendering
[WebProfilerBundle] Normalize whitespace in exceptions passed in headers
Disable color support detection for tests
[Form] Improve the exceptions when trying to get the data in a PRE_SET_DATA listener and the data has not already been set
This PR was merged into the 3.3-dev branch.
Discussion
----------
[DI] add ServiceLocatorTagPass::register() to share service locators
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Right now, one service locator is created per controller / service subscriber. But since service locators are stateless, this is just wasting resources when several controllers have the exact same set of services managed by their locators (as would be the case when registering the new `AbstractController` as a service subscribers).
This PR fixes this issue, and a few related others found along the way.
Commits
-------
8ff764be82 [DI] add ServiceLocatorTagPass::register() to share service locators
This PR was merged into the 3.3-dev branch.
Discussion
----------
[DI] Dont trigger deprecation for event_dispatcher service
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22208
| License | MIT
| Doc PR | n/a
Mute deprecations for the event_dispatcher service keeping only relevant ones i.e when the api of the deprecated class is used intentionally, ugly but prevent breaking test suites like the [LexikJWTAuthenticationBundle one](https://travis-ci.org/lexik/LexikJWTAuthenticationBundle/jobs/216664013#L278).
Commits
-------
a49fe25fa3 [DI] Dont trigger deprecation for event_dispatcher service
* 2.7:
Lighten tests output by removing composer suggestions
CS: Remove invisible chars
Disable resource tracking if the config component is missing
[EventDispatcher] Remove unneded count()
Fix tests expecting a valid date
[Console] Fix table cell styling
[Console] Revised exception rendering
[WebProfilerBundle] Normalize whitespace in exceptions passed in headers
Disable color support detection for tests
[Form] Improve the exceptions when trying to get the data in a PRE_SET_DATA listener and the data has not already been set
This PR was merged into the 3.3-dev branch.
Discussion
----------
[HttpKernel] Dont implement ServiceSubscriberInterface on *SessionListener
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22171, silexphp/Silex#1496
| License | MIT
| Doc PR | -
Implementing `ServiceSubscriberInterface` creates a dep on the DI component, which Silex can't afford. Let's revert that part.
@GromNaN can you please confirm this fixes your issue?
Commits
-------
7cd90f5c97 [HttpKernel] Dont implement ServiceSubscriberInterface on *SessionListener
This PR was merged into the 2.7 branch.
Discussion
----------
[WebProfilerBundle] Normalize whitespace in exceptions passed in headers
| Q | A
| ------------- | ---
| Branch? | 2.7 upwards
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #22072
| License | MIT
If an exception was thrown with line separators in its message the WebProfiler would cause an exception by passing it through unsanitized into the X-Debug-Error HTTP header. This commit fixes that by replacing all whitespace sequences with a single space in the header.
Commits
-------
d64679014b [WebProfilerBundle] Normalize whitespace in exceptions passed in headers
Errors reported by Sami API Doc generator on branch 3.2
ERROR: The "factory" @param tag variable name is wrong (should be "objectLoader") on "Symfony\Bridge\Doctrine\Form\ChoiceList\DoctrineChoiceLoader::__construct" in src/Symfony/Bridge/Doctrine/Form/ChoiceList/DoctrineChoiceLoader.php:68
ERROR: The "objectLoader" @param tag variable name is wrong (should be "factory") on "Symfony\Bridge\Doctrine\Form\ChoiceList\DoctrineChoiceLoader::__construct" in src/Symfony/Bridge/Doctrine/Form/ChoiceList/DoctrineChoiceLoader.php:68
ERROR: "7" @param tags are expected but only "6" found on "Symfony\Bundle\WebProfilerBundle\Controller\ProfilerController::__construct" in src/Symfony/Bundle/WebProfilerBundle/Controller/ProfilerController.php:50
ERROR: "3" @param tags are expected but only "2" found on "Symfony\Component\Asset\PathPackage::__construct" in src/Symfony/Component/Asset/PathPackage.php:35
ERROR: "2" @param tags are expected but only "1" found on "Symfony\Component\Cache\Adapter\PhpArrayAdapter::create" in src/Symfony/Component/Cache/Adapter/PhpArrayAdapter.php:64
ERROR: "3" @param tags are expected but only "1" found on "Symfony\Component\Cache\Adapter\RedisAdapter::__construct" in src/Symfony/Component/Cache/Adapter/RedisAdapter.php:39
ERROR: The "format" @param tag variable name is wrong (should be "fileLinkFormat") on "Symfony\Component\Debug\ExceptionHandler::setFileLinkFormat" in src/Symfony/Component/Debug/ExceptionHandler.php:90
ERROR: "2" @param tags are expected but only "3" found on "Symfony\Component\DependencyInjection\Compiler\Compiler::addPass" in src/Symfony/Component/DependencyInjection/Compiler/Compiler.php:73
ERROR: "2" @param tags are expected but only "3" found on "Symfony\Component\DependencyInjection\Compiler\PassConfig::addPass" in src/Symfony/Component/DependencyInjection/Compiler/PassConfig.php:97
ERROR: "2" @param tags are expected but only "3" found on "Symfony\Component\DependencyInjection\ContainerBuilder::addCompilerPass" in src/Symfony/Component/DependencyInjection/ContainerBuilder.php:311
ERROR: "2" @param tags are expected but only "3" found on "Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface::getProxyFactoryCode" in src/Symfony/Component/DependencyInjection/LazyProxy/PhpDumper/DumperInterface.php:41
ERROR: "0" @param tags are expected but only "1" found on "Symfony\Component\HttpFoundation\Request::isMethodSafe" in src/Symfony/Component/HttpFoundation/Request.php:1458
ERROR: "5" @param tags are expected but only "6" found on "Symfony\Component\Serializer\Normalizer\AbstractNormalizer::instantiateObject" in src/Symfony/Component/Serializer/Normalizer/AbstractNormalizer.php:291
If an exception was thrown with line separators in its message the
WebProfiler would cause an exception by passing it through unsanitized
into the X-Debug-Error HTTP header. This commit fixes that by replacing
all whitespace sequences with a single space in the header.
* 3.2:
[Bridge\Doctrine] Fix change breaking doctrine-bundle test suite
[WebProfilerBundle] Include badge status in translation tabs
[FrameworkBundle] Cache pool clear command requires at least 1 pool
[HttpFoundation][bugfix] should always be initialized
MockArraySessionStorage: updated phpdoc for $bags so that IDE autocompletion would work
normalize paths before making them relative
removed test that does not test anything
fixed tests
#21809 [SecurityBundle] bugfix: if security provider's name contains upper cases then container didn't compile
[WebProfilerBundle] Fix for CSS attribute at Profiler Translation Page
Set Date header in Response constructor already
[Validator] fix URL validator to detect non supported chars according to RFC 3986
[Security] Fixed roles serialization on token from user object
This PR was merged into the 3.3-dev branch.
Discussion
----------
[DI] Add "by-id" autowiring: a side-effect free variant of it based on the class<>id convention
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This PR adds a new autowiring mode, based only on the class <> id convention.
This way of autowiring is free from any conflicting behavior, which is what I was looking for to begin with.
The expected DX is a bit more involving than the current way we do autowiring. But it's worth it to me, because it's plain predictable - a lot less "magic" imho.
So in this mode, for each `App\Foo` type hint, a reference to an "App\Foo" service will be created. If no such service exists, an exception will be thrown. To me, this opens a nice DX: when type hinting interfaces (which is the best practice), this will tell you when you need to create the explicit interface <> id mapping that is missing - thus encourage things to be made explicit, but only when required, and gradually, in a way that will favor discoverability by devs.
Of course, this is opt-in, and BC. You'd need to do eg in yaml: `autowire: by_id`.
For consistency, the current mode (`autowire: true`) can be configured using `autowire: by_type`.
Commits
-------
c298f2a90c [DI] Add "by-id" autowiring: a side-effect free variant of it based on the class<>id convention
This PR was squashed before being merged into the 3.3-dev branch (closes#22046).
Discussion
----------
[Asset] Adding a new version strategy that reads from a manifest JSON file
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/issues/7659
Hi guys!
Often, when using a frontend task manager or bundler (e.g. webpack of gulp), the final assets are dumped with a version or content hash in the filename itself (e.g. main.123abc.css). To know what the correct, current hashed filename is, you'll dump a `manifest.json` file - e.g.
```json
{
"main.js": "main.123abc.js",
"css/styles.css": "css/styles.555def.css"
}
```
Examples: [gulp-rev](https://github.com/sindresorhus/gulp-rev) and [webpack-manifest-plugin](https://www.npmjs.com/package/webpack-manifest-plugin).
This PR adds a new version strategy that will look up the asset path (e.g. `main.css`) in that file and return the final, versioned path. Some people may dump manifest files in other formats, but I think this catches the most common use-case (and you can always still create your own version strategy). I've written this to be "forgiving" - if a path doesn't exist in the manifest, the path is simply returned, unaltered.
Another implementation *could* have been to add a new Twig filter (e.g. `{{ asset('main.css|manifest_path) }}`) - but I thought I'd try first using the existing versioning system.
## Usage
```yml
# app/config/config.yml
framework:
# ...
assets:
# added validation prevents you from setting json_manifest_path AND version, for example
json_manifest_path: '%kernel.root_dir%/../web/manifest.json'
```
```twig
{# someTemplate.html.twig #}
{# use asset() just like normal #}
<script src="{{ asset('js/main.js') }}"></script>
```
## TODO
* fabbot hates my invalid json syntax file... even though I tried to be clever and not give it a `.json` suffix :)
Commits
-------
07fec2bbad [Asset] Adding a new version strategy that reads from a manifest JSON file
* 2.8:
removed test that does not test anything
fixed tests
#21809 [SecurityBundle] bugfix: if security provider's name contains upper cases then container didn't compile
[WebProfilerBundle] Fix for CSS attribute at Profiler Translation Page
Set Date header in Response constructor already
[Validator] fix URL validator to detect non supported chars according to RFC 3986
[Security] Fixed roles serialization on token from user object
* 2.7:
removed test that does not test anything
fixed tests
#21809 [SecurityBundle] bugfix: if security provider's name contains upper cases then container didn't compile
[Validator] fix URL validator to detect non supported chars according to RFC 3986
[Security] Fixed roles serialization on token from user object
This PR was squashed before being merged into the 3.3-dev branch (closes#22120).
Discussion
----------
[FrameworkBundle] Multiple services on one Command class
rebased version of #19305
Commits
-------
2b82fcb437 [FrameworkBundle] Multiple services on one Command class
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle] Add new "controller.service_arguments" tag to inject services into actions
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | (no test yet)
| Fixed tickets | -
| License | MIT
| Doc PR | -
Talking with @simensen and @weaverryan, we wondered if we could leverage the `ArgumentResolver` mechanism to make it inject services on demand, using e.g. autowiring.
```php
class PostController
{
public function indexAction(Request $request, PostRepository $postRepository)
{
// PostRepository comes from the container
$postRepository->findAll(); // ...
}
}
```
This PR achieves that, using a new "controller.service_arguments" tag. Typically:
```yaml
services:
AppBundle\Controller\PostController:
autowire: true
tags:
- name: controller.service_arguments
```
It also supports with explicit wiring (thus doesn't necessarily require autowiring if you don't want to use it):
```yaml
services:
AppBundle\Controller\PostController:
tags:
- name: controller.service_arguments
action: fooAction
argument: logger
id: my_logger
```
~~The attached diff is bigger than strictly required for now, until #21770 is merged.~~
Todo:
- [x] rebase on top of #21770 when merged
- [x] add tests
- [x] add cleaning pass to remove empty service locators
Commits
-------
9c6e672780 [FrameworkBundle] Add new "controller.service_arguments" tag to inject services into actions
* 3.2:
Fixed pathinfo calculation for requests starting with a question mark.
[HttpFoundation] Fix missing handling of for/host/proto info from "Forwarded" header
[Validator] Add object handling of invalid constraints in Composite
[WebProfilerBundle] Remove uneeded directive in the form collector styles
removed usage of $that
HttpCache: New test for revalidating responses with an expired TTL
[Serializer] [XML] Ignore Process Instruction
[Security] simplify the SwitchUserListenerTest
Revert "bug #21841 [Console] Do not squash input changes made from console.command event (chalasr)"
[HttpFoundation] Fix Request::getHost() when having several hosts in X_FORWARDED_HOST
This PR was merged into the 3.3-dev branch.
Discussion
----------
[Security][SecurityBundle] Enhance automatic logout url generation
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | yes
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
This should help whenever:
- [the token does not implement the `getProviderKey` method](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Security/Http/Logout/LogoutUrlGenerator.php#L89-L99)
- you've got multiple firewalls sharing a same context but a logout listener only define on one of them.
##### Behavior:
> When not providing the firewall key:
>
>- Try to find the key from the token (unless it's an anonymous token)
>- If found, try to get the listener from the key. If the listener is found, stop there.
>- Try from the injected firewall key. If the listener is found, stop there.
>- Try from the injected firewall context. If the listener is found, stop there.
>
>The behavior remains unchanged when providing explicitly the firewall key. No fallback.
Commits
-------
5b7fe852aa [Security][SecurityBundle] Enhance automatic logout url generation
This PR was squashed before being merged into the 3.3-dev branch (closes#22112).
Discussion
----------
Minor PR fixes
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes-ish
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!--highly recommended for new features-->
cc @fabpot my bad :)
Commits
-------
0728fb91b8 typo
036b0414d6 Minor PR fixes
This PR was merged into the 3.3-dev branch.
Discussion
----------
[WebProfilerBundle] Improved cookie traffic
| Q | A
| ------------- | ---
| Branch? | "master"
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | comma-separated list of tickets fixed by the PR, if any
| License | MIT
| Doc PR | reference to the documentation PR, if any
![image](https://cloud.githubusercontent.com/assets/1047696/20455635/a033a814-ae60-11e6-8500-e60146f4619e.png)
Relates to #20569 in terms of getting _all_ the cookies.
Commits
-------
171c6d100e [WebProfilerBundle] Improved cookie traffic
* 2.8:
[HttpFoundation] Fix missing handling of for/host/proto info from "Forwarded" header
[Validator] Add object handling of invalid constraints in Composite
[WebProfilerBundle] Remove uneeded directive in the form collector styles
Revert "bug #21841 [Console] Do not squash input changes made from console.command event (chalasr)"
[HttpFoundation] Fix Request::getHost() when having several hosts in X_FORWARDED_HOST
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle][Serializer] Add option to register a circular_reference_handler
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
---
Right now, it's quite hard (especially for new comers) to register a CircularReferenceHandler:
![screenshot1](https://cloud.githubusercontent.com/assets/408368/23959193/ce19bcec-09a4-11e7-82c7-80abd7b7f602.png)
---
This PR introduce an option to wire a service to the internal Object Normalizer.
Commits
-------
0a638f5352 [FrameworkBundle][Serializer] Add option to register a "circular_reference_handler"
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle] Add project directory default for installing assets
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #20337
| License | MIT
| Doc PR |
This allows the `assets:install` console command to have a fallback default of the project root directory.
Current behavior is to install assets only in the `target` of the current working directory.
Commits
-------
7a11f3ecf3 [FrameworkBundle] Add project directory default for installing assets
This PR was squashed before being merged into the 3.3-dev branch (closes#20365).
Discussion
----------
[TwigBridge] Handle form label attributes like others
| Q | A |
| --- | --- |
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no |
| Deprecations? | no |
| Tests pass? | yes
| Fixed tickets | -
| License | MIT |
| Doc PR | -
The HTML for rendering attributes is duplicated in multiple blocks, making it error prone/hard to maintain.
Next, the label attributes followed a different approach. Imo. all should follow the same base rendering, showing the above is actually an issue.
Commits
-------
e317e0aeab [TwigBridge] Handle form label attributes like others
This PR was merged into the 3.3-dev branch.
Discussion
----------
[*Bundle] Add autowiring aliases for common services
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
As spotted while working on #22060, we're missing many aliases to prevent any autowiring ambiguities.
I also removed the "Symfony\Component\EventDispatcher\EventDispatcher" and "Symfony\Component\DependencyInjection\Container" aliases: we'd better encourage using the corresponding interfaces instead.
On ControllerTrait, we need to type hint against SessionInterface, because otherwise, when session support is disabled, autowiring still auto-registers an "autowired.Session" service, which defeats the purpose of being able to enable/disable it.
Commits
-------
08c2ee32f1 [*Bundle] Add autowiring aliases for common services
* 3.2:
Fixes a typo in the form collector styles
[WebProfilerBundle] Fix content-security-policy compatibility
[WebProfilerBundle] Drop dead code
[HttpKernel] Fixed bug with purging of HTTPS URLs
fix some risky tests
[DI] [YamlFileLoader] change error message of a non existing file
[WebProfilerBundle] Handle Content-Security-Policy-Report-Only header correctly
[Security] Added option to return true in the method isRememberMeRequested
* 2.8:
Fixes a typo in the form collector styles
[HttpKernel] Fixed bug with purging of HTTPS URLs
fix some risky tests
[DI] [YamlFileLoader] change error message of a non existing file
[Security] Added option to return true in the method isRememberMeRequested
* 2.7:
[HttpKernel] Fixed bug with purging of HTTPS URLs
fix some risky tests
[DI] [YamlFileLoader] change error message of a non existing file
[Security] Added option to return true in the method isRememberMeRequested
This PR was merged into the 3.2 branch.
Discussion
----------
[WebProfilerBundle] Handle Content-Security-Policy-Report-Only header correctly
| Q | A
| ------------- | ---
| Branch? | 3.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
This header should have been handled from the beginning.
Content-Security-Policy recommendation specify this header, it needs to be correctly handled
Commits
-------
b0ba698111 [WebProfilerBundle] Handle Content-Security-Policy-Report-Only header correctly
* 3.2:
[Yaml] CS
[DI] Fix PhpDumper generated doc block
#20411 fix Yaml parsing for very long quoted strings
[Workflow] add Phpdoc for better IDE support
fix package name in conflict rule
improve message when workflows are missing
[Doctrine Bridge] fix priority for doctrine event listeners
Use PHP functions as array_map callbacks when possible
[Validator] revert wrong Phpdoc change
Use proper line endings
* 2.8:
[DI] Fix PhpDumper generated doc block
#20411 fix Yaml parsing for very long quoted strings
[Doctrine Bridge] fix priority for doctrine event listeners
Use PHP functions as array_map callbacks when possible
[Validator] revert wrong Phpdoc change
Use proper line endings
* 2.7:
#20411 fix Yaml parsing for very long quoted strings
[Doctrine Bridge] fix priority for doctrine event listeners
Use PHP functions as array_map callbacks when possible
[Validator] revert wrong Phpdoc change
Use proper line endings
This will forbid using the FrameworkBundle in 3.3 with previous releases
of the Workflow to avoid issues related to the GuardListener class not
being present. Additionally, it provides a useful exception in case the
guard option is used without the ExpressionLanguage component being
installed.
This PR was merged into the 3.3-dev branch.
Discussion
----------
[DI] Introduce "container.service_locator" tag, replaces ServiceLocatorArgument
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no (master only)
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
I first started working on adding this new "container.service_locator" tag, so here it is.
It allows defining and dumping service-locator services properly, where it wasn't possible previously (you had to create a DI extension to do so.)
Then I realized that this allowed us to entirely drop `ServiceLocatorArgument` and replace it with the more flexible `ServiceClosureArgument`.
This makes things simpler overall, see diff stat.
Commits
-------
5d230b5871 [DI] Introduce "container.service_locator" tag, replaces ServiceLocatorArgument
This PR was merged into the 3.2 branch.
Discussion
----------
[FrameworkBundle] improve message when workflows are missing
| Q | A
| ------------- | ---
| Branch? | 3.2
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Commits
-------
46c12c9d1d improve message when workflows are missing
* 3.2:
[Cache] cache/integration-tests is now compatible with phpunit namespaces
[FrameworkBundle] Fix translation dep constraint
[Workflow] Added more tests
[Cache] Enhance error reporting for FilesystemAdapter
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle] Lazy configuration of annotations' loader and `@required`
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This would remove the need for https://github.com/symfony/symfony-standard/pull/1052 and for the `autoload.php` file altogether.
Tested on symfony-demo with great success so far.
Commits
-------
d332b37b4b [FrameworkBundle] Lazy configuration of annotations' loader and `@required`
This PR was merged into the 3.3-dev branch.
Discussion
----------
[FrameworkBundle][TwigBundle] Require PSR-11 container instead of Symfony container
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
As discussed in #21978 here is the second PR.
Commits
-------
857ce7c7be [FrameworkBundle][TwigBundle] Require PSR-11 container instead of Symfony container