This PR was merged into the 2.7 branch.
Discussion
----------
Fixed properties not explicitily declared
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | n/a
| License | MIT
Commits
-------
d2b3fe4 Fixed properties not explicitily declared
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes#15846).
Discussion
----------
[FrameworkBundle] Advanced search templates of bundles
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
It uses two different locations to search templates of bundle by `TemplateFinder`, as described in the documentation.
Useful for TwigBundle, in cases when uses the custom templates for error pages.
Commits
-------
3ba1460 [FrameworkBundle] Advanced search templates of bundles
This PR was merged into the 2.3 branch.
Discussion
----------
Use random_bytes function if it is available for random number generation
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #15239
| License | MIT
| Doc PR |
This is an attempt to use the random_bytes function when generating secure random numbers. This function is included in PHP 7 or through the "paragonie/random_compat" library.
This PR only adds support to use the function if it is available. Changes that can be added is to add a hard dependency on the paragonie/random_compat library, so all current functionality can be deprecated.
Commits
-------
6a217dc Use random_bytes function if it is available for random number generation
This PR was merged into the 2.3 branch.
Discussion
----------
[Security] Allow user providers to be defined in many files
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #15894
| License | MIT
| Doc PR | -
Commits
-------
9165191 [Security] Allow user providers to be defined in many files
This PR was merged into the 2.7 branch.
Discussion
----------
[Console] Fix transient HHVM test
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Follow up of #15848
Commits
-------
945ec0e [Console] Fix transient HHVM test
This PR was merged into the 2.7 branch.
Discussion
----------
[VarDumper] Fix dump comparison on large arrays
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
Commits
-------
6a6e7f3 [VarDumper] Fix dump comparison on large arrays
This PR was submitted for the 2.8 branch but it was merged into the 2.7 branch instead (closes#15878).
Discussion
----------
[OptionsResolver] Fix catched exception along the dependency tree mistakenly detects cyclic dependencies
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
| Doc PR | N/A
If an Option's normalizer (or lazy default) catches an exception thrown from one of its dependencies, the OptionResolver was left in an inconsistent state which would trigger a false positive cyclic dependency if the throwing option or any of its parent dependencies between it and the catching one are ever called again.
Commits
-------
9a188c5 [OptionsResolver] Fix catched exception along the dependency tree mistakenly detects cyclic dependencies
This PR was merged into the 2.7 branch.
Discussion
----------
Fixing security test locations
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | none
| License | MIT
| Doc PR | n/a
There were just missed on sha: 0601ed33c4 probably because there were on a different branch.
Cheers!
Commits
-------
16e09d3 Fixing test locations
This PR was merged into the 2.7 branch.
Discussion
----------
[expression-language] Code Cleanup for GetAttrNode
Use ``$this->nodes['attribute']->attributes['value']`` to
replace ``$this->nodes['attribute']->evaluate($functions, $values)``
for method call and property call.
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
166e175 [expression-language] Code Cleanup for GetAttrNode
This PR was merged into the 2.7 branch.
Discussion
----------
Normalize the way we check versions
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | N/A
| License | MIT
Commits
-------
121eade Normalize the way we check versions
* 2.3:
Finnish translation fix
[CssSelector] Optimize regexs matching simple selectors
Fix the phpdoc in the CssSelector TranslatorInterface
[Console] Add clock mock to fix transient test on HHVM
[EventDispatcher] skip one lazy loading call
[EventDispatcher] fix memory leak in a getListeners
This PR was merged into the 2.7 branch.
Discussion
----------
[Console] Default to stderr for the console helpers (2.7+)
Interactive input/output and informational output such as progress should go to `stderr` if available.
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets |
| License | MIT
| Doc PR |
Only merge if #15794 is merged.
If someone explicitly wants to use `stdout`, they can simply pass `$output->getStream()` instead of `$output` in most use-cases.
Commits
-------
90c2a96 Default to stderr for console helpers (only merge if #15794 gets merged)
This PR was merged into the 2.7 branch.
Discussion
----------
[Config] Fix enum default value in Yaml dumper
| Q | A
| ------------- | ---
| 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 default value is not correctly included when dumping an EnumNode in Yaml. This is now fixed
Commits
-------
d135d82 [Config] Fix enum default value in Yaml dumper
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes#15843).
Discussion
----------
Finnish translation fix
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #15790
| License | MIT
| Doc PR | -
Fix for finnish translation typo
https://github.com/symfony/symfony/issues/15790
Commits
-------
84fbfb0 Finnish translation fix
This PR was merged into the 2.3 branch.
Discussion
----------
[CssSelector] Optimize regexs matching simple selectors
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
These shortcut parsers are applied first when converting a CSS selector to XPath, to be faster for simple selectors (tag matching, class matching with an optional tag, id matching with an optional tag).
None of the regexes defined here could have more chances to match more element when backtracking identifiers. So the backtracking is only slowing down the regex engine when the regex does not match (i.e. for any more complex selector for instance, or even for simple selectors without namespace of without tag name). Making quantifiers possessive solves this issue.
I also turned some capturing groups (around the namespace and the namespace delimiter) into non-capturing groups as we don't care about them in the output (they are just here to be optional).
Commits
-------
d5abe0b [CssSelector] Optimize regexs matching simple selectors
This PR was merged into the 2.3 branch.
Discussion
----------
[Console] Add clock mock to fix transient test on HHVM
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
This should fix the most frequent transient test on HHVM (ProgressBarTest::testAnsiColorsAndEmojis)
Commits
-------
549f43b [Console] Add clock mock to fix transient test on HHVM
This PR was merged into the 2.3 branch.
Discussion
----------
Fix the phpdoc in the CssSelector TranslatorInterface
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
The phpdoc of the interface does not match the behavior of the implementation. And the return type documented by the interface is impossible to return because the interface asks to apply a string prefix, and the only way is to cast the ``XPathExpr`` used internally to a string (which is what the implementation does).
This interface is an internal interface anyway.
Commits
-------
93ffa61 Fix the phpdoc in the CssSelector TranslatorInterface
This PR was merged into the 2.7 branch.
Discussion
----------
[DomCrawler] Optimize the regex used to find namespace prefixes
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
I ran Blackfire on the [Mink BrowserKitDriver](https://github.com/minkphp/MinkBrowserKitDriver) testsuite (which is a realistic usage of the Mink API btw, as the driver testsuite is basically a functional test of a fixtures website, where failures are considered to be caused by the driver misbehaving).
I discovered that 17% of the time was spent in ``preg_match_all`` to look for prefixes in the XPath namespace prefixes (Mink does not use any namespace prefix in its Xpath queries).
This optimizes the regex to use a possessive quantifier. This avoids useless backtracking when matching (due to the way the regex is written, backtracking cannot allow finding more matches here). See https://blackfire.io/profiles/compare/21aaebf3-e38f-456a-8fc9-cf7d9e2a35eb/graph for the improvement.
The optimization is applied in the 2.7 branch, because this regex does not exist in 2.3: the registration of namespaces was added in 2.4
Commits
-------
02818e4 [DomCrawler] Optimize the regex used to find namespace prefixes
This PR was submitted for the master branch but it was merged into the 2.7 branch instead (closes#15836).
Discussion
----------
[Form] fixed something: Remove whitespaces between <input> and <label>
| Q | A
| ------------- | ---
| Bug fix? | [no]
| New feature? | [no]
| BC breaks? | [?] What means BC?
| Deprecations? | [no]
| Tests pass? | [yes]
| Fixed tickets | []
| License | MIT
| Doc PR | []
Reason: With the whitespaces, there would be a "gap" between `<input>` and `<label>` which is clickable, but doesn't activate the `<input>`.
It's easy to *add* some margin with CSS, whereas it's impossible to *remove* whitespaces with CSS.
Commits
-------
1b97c17 Remove whitespaces between <input> and <label>
Reason: With the whitespaces, there would be a "gap" between <input> and <label> which is clickable, but doesn't activate the <input>.
It's easy to *add* some margin with CSS, whereas it's impossible to *remove* whitespaces with CSS.