This PR was merged into the 3.4 branch.
Discussion
----------
[DI] Don't show internal service id on binding errors
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Will throw
Unused binding "$variableName" in service "App\Twig\AppExtension".
instead of the current
Unused binding "$variableName" in service ".abstract.instanceof.App\Twig\AppExtension".
Commits
-------
61f005af36 [DI] Don't show internal service id on binding errors
This PR was squashed before being merged into the 2.8 branch (closes#27836).
Discussion
----------
[HttpFoundation] add tests for FlashBagInterface::setAll()
| 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 | ~
Adding documentation for the `FlashBagInterface::setAll()` function
Commits
-------
af96475e2a [HttpFoundation] add tests for FlashBagInterface::setAll()
This PR was squashed before being merged into the 2.8 branch (closes#27831).
Discussion
----------
Check for Hyper terminal on all operating systems.
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
return true if the terminal is Hyper.is on all operating systems not limited to windows.
Commits
-------
196e708b68 Check for Hyper terminal on all operating systems.
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Security] Use AuthenticationTrustResolver in SimplePreAuthenticationListener
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes (minor)
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Minor, but would be consistent with how `ContextListener` checks for anonymous tokens.
Commits
-------
27b89cb [Security] Use AuthenticationTrustResolver in SimplePreAuthenticationListener
This PR was squashed before being merged into the 4.2-dev branch (closes#27830).
Discussion
----------
[Dependency-Injection] Fix issue where non-defined services were attempted to be removed
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | #27802 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | symfony/symfony-docs#... <!-- required for new features -->
The RemoveUnusedServicesPass generates a graph of services that are connected, then removes services that are not part of the graph. To build this graph it creates a list of services then examines their definitions for more services.
The current scenario was causing an error, thrown by getDefinition (triggered in Behat):
* Service was referenced by another service definition
* Service was _not_ defined
* Service was subsequently set() on the container
Commits
-------
53155c9800 [Dependency-Injection] Fix issue where non-defined services were attempted to be removed
* 4.1:
Add color support for Hyper terminal .
[HttpFoundation] Fix tests: new message for status 425
[Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
[Workflow] Update phpdoc to fit a used className
[PropertyInfo] added handling of nullable types in PhpDoc
[HttpKernel] Make AbstractTestSessionListener compatible with CookieClearingLogoutHandler
[Cache] provider does not respect option maxIdLength with versioning enabled
[Form] Fix fixtures for forward compat
[Lock] Fix SemaphoreStoreTest on OS X
Ensure the class discriminator mechanism works with serialization groups as well
fix handling of empty DI extension configs
* 4.0:
Add color support for Hyper terminal .
[HttpFoundation] Fix tests: new message for status 425
[Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
[PropertyInfo] added handling of nullable types in PhpDoc
[HttpKernel] Make AbstractTestSessionListener compatible with CookieClearingLogoutHandler
[Cache] provider does not respect option maxIdLength with versioning enabled
* 3.4:
Add color support for Hyper terminal .
[HttpFoundation] Fix tests: new message for status 425
[Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
[PropertyInfo] added handling of nullable types in PhpDoc
[HttpKernel] Make AbstractTestSessionListener compatible with CookieClearingLogoutHandler
[Cache] provider does not respect option maxIdLength with versioning enabled
* 2.8:
Add color support for Hyper terminal .
[HttpFoundation] Fix tests: new message for status 425
[Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
This PR was merged into the 2.8 branch.
Discussion
----------
[Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27811
| License | MIT
This change prevents error when invalid subscriber is being used.
Expected result:
```
The Doctrine connection "root" referenced in service "stof_doctrine_extensions.listener.sluggable" does not exist. Available connections names: default
```
Actual error:
```
Notice: Array to string conversion
```
Commits
-------
cf1bc66464 [Doctrine Bridge] Fixed usage of wrong variable when tagged subscriber is invalid
This PR was merged into the 4.2-dev branch.
Discussion
----------
[MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | https://github.com/symfony/symfony-docs/pull/9996
Using this, enabling e.g. TokenProcessor or WebProcessor just needs one line in `services.yaml`:
```yaml
services:
Symfony\Bridge\Monolog\Processor\TokenProcessor: ~
Symfony\Bridge\Monolog\Processor\WebProcessor: ~
```
Commits
-------
28a4912f21 [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Security/Http] report file+line of unserialization errors in Firewall/ContextListener
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
9adb0c7e42 [Security/Http] report file+line of unserialization errors in Firewall/ContextListener
This PR was submitted for the master branch but it was merged into the 2.8 branch instead (closes#27794).
Discussion
----------
Add color support for Hyper terminal .
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| License | MIT
Added color support for [Hyper terminal](https://hyper.is), also shade characters support for progress bar.
![image](https://user-images.githubusercontent.com/29315886/42135797-6edb8492-7d50-11e8-968b-2dd19981dcdd.png)
Commits
-------
2ab7bcf797 Add color support for Hyper terminal .
This PR was squashed before being merged into the 2.8 branch (closes#27809).
Discussion
----------
[HttpFoundation] Fix tests: new message for status 425
| Q | A
| ------------- | ---
| Branch? | 2.8
| Bug fix? | yes
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | n/a
Makes tests green.
The new meaning of 425 is defined here: https://datatracker.ietf.org/doc/draft-ietf-httpbis-replay/?include_text=1
Commits
-------
8e37d77145 [HttpFoundation] Fix tests: new message for status 425
This PR was merged into the 4.1 branch.
Discussion
----------
[Workflow] Update phpdoc to fit a used className
| Q | A
| ------------- | ---
| Branch? | 4.1
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR | none
It will just help IDE and static analysis tools to work correctly.
I could also add a `use Symfony\Component\Workflow\Workflow;` if you prefer
Commits
-------
89470f19cc [Workflow] Update phpdoc to fit a used className
This PR was merged into the 3.4 branch.
Discussion
----------
[PropertyInfo] added handling of nullable types in PhpDoc
While not specified in PSR-5, PhpDocumentor does support parsing nullable types in the PHP 7.1 syntax (i.e. `?string`), and returns those in a `Nullable` wrapper type. We currently don't handle this and neither throw an error, which results in all kind of weird breakage when this syntax is used (e.g. "class string|int not found").
Correctly parse this syntax into a nullable type.
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
38b369be3f [PropertyInfo] added handling of nullable types in PhpDoc
While not specified in PSR-5, PhpDocumentor does support parsing
nullable types in the PHP 7.1 syntax (i.e. ?string), and returns those
in a Nullable wrapper. We currently don't handle this and neither throw
an error, which results in all kind of weird breakage when this syntax
is used (e.g. "class string|int not found").
Correctly parse this syntax into a nullable type.
This PR was merged into the 4.2-dev branch.
Discussion
----------
[VarDumper] make control characters non-selectable in HTML
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes
| BC breaks? | maybe
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #23921
| License | MIT
| Doc PR | -
### Overview
This fixes long term annoyance with control characters in dumps. It makes dumps unusable to use with e.g. SQLs, since copying them will leave `\n` (and others).
### Changes
This PR does three things:
1. Adds special class of characters abbreviated as `ctrl` (cosmetic, already exists in fact but it's not exposed in HTML)
2. Makes control characters non-selectable
3. Changes color of control character from default orange to grey (used by Symfony.com dark theme) which improves UX by showing *"hey, this is something special"*
### Preview
**Inline dump**
<img width="243" alt="screenshot 2018-05-19 17 26 18" src="https://user-images.githubusercontent.com/1227834/40273711-7d963450-5b8b-11e8-843a-dda1e2719b59.png">
**Web Profiler**
<img width="418" alt="screenshot 2018-05-19 17 38 36" src="https://user-images.githubusercontent.com/1227834/40273714-86b9cfec-5b8b-11e8-898b-b7cb5f150a72.png">
<img width="533" alt="screenshot 2018-05-19 17 20 42" src="https://user-images.githubusercontent.com/1227834/40273720-a2370852-5b8b-11e8-88c7-aed9281cc056.png">
**Dump Server**
<img width="194" alt="screenshot 2018-05-19 17 30 12" src="https://user-images.githubusercontent.com/1227834/40273722-aa444686-5b8b-11e8-9ae9-ea2eebb3368d.png">
Commits
-------
b0d4c99bf4 [VarDumper] make control characters non-selectable in HTML
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Serializer] Allow to pass a single value for the groups opt
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | n/a
| License | MIT
| Doc PR | todo
Shortcut syntax similar to #20509 but for the context: allows to pass a string instead of an array of string in the serialization context when only one group if used.
Before:
```php
$serializer->serialize($foo, 'json', ['groups' => ['myGroup']];
/** @ApiResource(normalizationContext={"groups"={"myGroup"}}) */
```
After:
```php
$serializer->serialize($foo, 'json', ['groups' => 'myGroup'];
/** @ApiResource(normalizationContext={"groups"="myGroup") */
```
Commits
-------
5b392030f9 [Serializer] Allow to pass a single value for the groups opt
This PR was squashed before being merged into the 3.4 branch (closes#27659).
Discussion
----------
[HttpKernel] Make AbstractTestSessionListener compatible with CookieClearingLogoutHandler
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
#26157 started to send a new cookie in `AbstractTestSessionListener`, but is incompatible with `CookieClearingLogoutHandler` as it overrides its `Set-Cookie` by setting a new cookie (breaking my test that checked to see that the cookie was removed after a log out).
Commits
-------
f54d96926a [HttpKernel] Make AbstractTestSessionListener compatible with CookieClearingLogoutHandler
This PR was squashed before being merged into the 3.4 branch (closes#27752).
Discussion
----------
[Cache] provider does not respect option maxIdLength with versioning enabled
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #27746
| License | MIT
| Doc PR |
Component symfony/cache generates cache item ID longer then maxIdLength when versioning is enabled
Commits
-------
ba8b63b195 [Cache] provider does not respect option maxIdLength with versioning enabled
This PR was merged into the 3.4 branch.
Discussion
----------
[Form] Fix fixtures for forward compat
| Q | A
| ------------- | ---
| Branch? | 3.4 <!-- see below -->
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | https://travis-ci.org/symfony/symfony/jobs/398533738#L4394-L4407 <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Completes https://github.com/symfony/symfony/pull/27771 in order to fix https://travis-ci.org/symfony/symfony/jobs/398533738#L4394-L4407. As the Closure signature is variable, we cannot assume the exact number of whitespaces after it, nor if it will or not overtake the length of the `file:` line. So let's just assume an undetermined nb of whitespaces.
Commits
-------
582d797b16 [Form] Fix fixtures for forward compat
This PR was merged into the 4.2-dev branch.
Discussion
----------
Respect alpha order in UPGRADE-4.2 file
| Q | A
| ------------- | ---
| Branch? | master <!-- see below -->
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
Commits
-------
d5c1cc04c8 Respect alpha order in UPGRADE-4.2 file
This PR was merged into the 4.2-dev branch.
Discussion
----------
[Serializer] Deprecate CsvEncoder as_collection false default value
| Q | A
| ------------- | ---
| Branch? | master <!-- see below -->
| Bug fix? | no
| New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks? | no <!-- see https://symfony.com/bc -->
| Deprecations? | yes <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass? | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License | MIT
| Doc PR | N/A
As already expressed in https://github.com/symfony/symfony/pull/25369 and related issues, this behavior is quite counter-intuitive. It may be fine for write-API with a single document in the body but I think such CSV APIs are way less common than file-based ones, expecting collections. So I think this behavior should be opt-in explicitly in required cases, always dealing with collections by default.
This is still an arbitrary decision, but trying to make it based on use-cases and user's experience with CSV.
Note: perhaps we could find a better name for this as the semantic of setting `as_collection` to `false` to get the single row directly would not be really obvious.
Also, it could throw an exception when getting multiple rows where only one was expected.
Commits
-------
bce59c8427 [Serializer] Deprecate CsvEncoder as_collection false default value