Commit Graph

32924 Commits

Author SHA1 Message Date
darnel
fbe7148000 Fix translation for "This field was not expected"
Update validators.cs.xlf - Fix czech translation for "This field was not expected"
2017-09-28 08:55:08 +02:00
Maxime Steinhausser
7d749bfb77 [Routing] Enhance PHP DSL traits docblocks 2017-09-28 08:00:01 +02:00
Fabien Potencier
d7885ec3b2 minor #24352 Fix AclSchemaListener deprecation (chalasr)
This PR was merged into the 3.4 branch.

Discussion
----------

Fix AclSchemaListener deprecation

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| 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
-------

eebe39e600 Fix AclSchemaListener deprecation
2017-09-27 14:49:24 -07:00
Robin Chalas
eebe39e600 Fix AclSchemaListener deprecation 2017-09-27 23:42:53 +02:00
Fabien Potencier
b46f9956c2 feature #24349 [SecurityBundle] Add missing AclSchemaListener deprecation (ogizanagi)
This PR was merged into the 3.4 branch.

Discussion
----------

[SecurityBundle] Add missing AclSchemaListener deprecation

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| 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 | N/A <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

Missing from #24318

Commits
-------

d43c1f7b60 [SecurityBundle] Add missing AclSchemaListener deprecation
2017-09-27 14:28:13 -07:00
Maxime Steinhausser
5b4308e9e1 [Routing] Enhance Route(Collection) docblocks 2017-09-27 23:22:30 +02:00
Maxime Steinhausser
d43c1f7b60 [SecurityBundle] Add missing AclSchemaListener deprecation 2017-09-27 21:54:46 +02:00
Fabien Potencier
7269013ff3 feature #24202 [Filesystem] deprecate relative paths in makePathRelative() (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

[Filesystem] deprecate relative paths in makePathRelative()

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Commits
-------

893df5804e deprecate relative paths in makePathRelative()
2017-09-27 12:24:44 -07:00
Fabien Potencier
f7eb7972ff fixed CS 2017-09-27 10:32:40 -07:00
Fabien Potencier
94aef22fec feature #21716 [Serializer] Add Support for object_to_populate in CustomNormalizer (chrisguitarguy)
This PR was squashed before being merged into the 3.4 branch (closes #21716).

Discussion
----------

[Serializer] Add Support for `object_to_populate` in CustomNormalizer

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #21715
| License       | MIT
| Doc PR        | n/a

This pulls a trait out of `AbstractNormalizer` with a method to extract the object to populate and adds some tests for it. Then uses that trait in both `AbstractNormalizer` and `CustomNormalizer` so both can support the `object_to_populate` key.

Commits
-------

ec9242d1ee [Serializer] Add Support for  in CustomNormalizer
2017-09-27 10:32:13 -07:00
Christopher Davis
ec9242d1ee [Serializer] Add Support for in CustomNormalizer 2017-09-27 10:32:12 -07:00
Fabien Potencier
f56f28b0f3 feature #21960 Remove Validator\TypeTestCase and add validator logic to base TypeTestCase (pierredup)
This PR was squashed before being merged into the 3.4 branch (closes #21960).

Discussion
----------

Remove Validator\TypeTestCase and add validator logic to base TypeTestCase

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no/possibly
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | N/A
| License       | MIT
| Doc PR        | symfony/symfony-docs#7587

Based on a discussion in the docs, users should not really extend classes in the `Tests` namespace. This means that if you want to unit test forms, you need to extend the `Test\TypeTestCase` class which doesn't have the validation logic (Not adding the validator extension gives an error if you use the `constraints` option in your forms).
So I propose to remove the `Validator\TypeTestCase` class (or it can possibly be deprecated if it is wrongly used by someone), and add the validator extension logic to the base `TypTestCase` class.

The benefit is that there is only one class to extend (both for internal or userland tests), and it makes it easy to add more core extensions if necessary.

The one part that I don't like too much at the moment, is keeping the extension in the `getExtensions` method. This means that you extend the class and need to register custom extensions, that you would need to do `return array_merge(parent::getExtensions(), ... ` (only in the case when you want core extensions enabled). So I don't know if we rather want to add a private method like `getCoreExtensions`?

Commits
-------

5ab50103ae Remove Validator\TypeTestCase and add validator logic to base TypeTestCase
2017-09-27 09:12:49 -07:00
Pierre du Plessis
5ab50103ae Remove Validator\TypeTestCase and add validator logic to base TypeTestCase 2017-09-27 09:12:32 -07:00
Fabien Potencier
e5ddd14b1d feature #22113 [Lock] Include lock component in framework bundle (jderusse)
This PR was squashed before being merged into the 3.4 branch (closes #22113).

Discussion
----------

[Lock] Include lock component in framework bundle

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | none
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/8066

## Usage

use the best available "out of box" store (semaphore if available, filesyste otherwise)
```yml
framework:
    lock: ~
    # lock: true
```

```php
$this->get('lock')->acquire();
$this->get('lock.factory')->createLock('my resource')->acquire();
```

use a specific store
```yml
framework:
    lock: flock
    # lock: semaphore
    # lock: redis://localhost
    # lock: "%env(MEMCACHED_DSN)%"
    # lock: ["%env(REDIS_DSN_1)%", "%env(REDIS_DSN_2)%"]
```

```php
$this->get('lock')->acquire();
$this->get('lock.factory')->createLock('my resource')->acquire();
```

use a named lock
```yml
framework:
    lock:
        foo: flock
        bar: redis://localhost
```

```php
$this->get('lock.foo')->acquire();
$this->get('lock.bar.factory')->createLock('my resource')->acquire();
```

factory usage

```xml
        <service id="acme" class="AppBundle\Acme">
            <argument type="service">
                <service class="Symfony\Component\Lock\Lock">
                    <factory service="lock.foo.factory" method="createLock" />
                    <argument>my resource</argument>
                    <argument>30</argument> <!-- optional TTL -->
                </service>
            </argument>
        </service>
```

* [x] Tests

Commits
-------

b4b00c9c6f [Lock] Include lock component in framework bundle
2017-09-27 08:10:57 -07:00
Jérémy Derussé
b4b00c9c6f [Lock] Include lock component in framework bundle 2017-09-27 08:10:55 -07:00
Fabien Potencier
9ebe2185bd feature #24236 [WebProfilerBundle] Render file links for twig templates (ro0NL)
This PR was squashed before being merged into the 3.4 branch (closes #24236).

Discussion
----------

[WebProfilerBundle] Render file links for twig templates

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes/no
| Fixed tickets | #24218
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!--highly recommended for new features-->

![image](https://user-images.githubusercontent.com/1047696/30515418-8c4615c6-9b27-11e7-8e26-8caa30ff7cbb.png)

Also tweaked default code color a bit for yaml, twig and the like.

Before
![image](https://user-images.githubusercontent.com/1047696/30515499-2231d768-9b29-11e7-8cab-a61537e83343.png)

After
![image](https://user-images.githubusercontent.com/1047696/30515504-354ea218-9b29-11e7-9457-518e9413e6f9.png)

Commits
-------

860575a882 [WebProfilerBundle] Render file links for twig templates
2017-09-27 07:36:24 -07:00
Roland Franssen
860575a882 [WebProfilerBundle] Render file links for twig templates 2017-09-27 07:36:23 -07:00
Fabien Potencier
9f56a9efa7 feature #21239 [Serializer] throw more specific exceptions (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

[Serializer] throw more specific exceptions

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #20534
| License       | MIT
| Doc PR        |

Commits
-------

aa30d04243 [Serializer] throw more specific exceptions
2017-09-27 07:28:41 -07:00
Fabien Potencier
65872e8c3a feature #24256 CsvEncoder handling variable structures and custom header order (Oliver Hoff)
This PR was squashed before being merged into the 3.4 branch (closes #24256).

Discussion
----------

CsvEncoder handling variable structures and custom header order

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23278
| License       | MIT
| Doc PR        | TBD

This PR improves the CsvEncoder to handle variable nesting structures and adds a context option that allows custom csv header order.

Commits
-------

d173494e48 CsvEncoder handling variable structures and custom header order
2017-09-27 07:20:06 -07:00
Oliver Hoff
d173494e48 CsvEncoder handling variable structures and custom header order 2017-09-27 07:19:39 -07:00
Christophe Coevoet
250d56b8d7 minor #21620 [Security] Saltless Encoder Interface (zanbaldwin)
This PR was merged into the 3.4 branch.

Discussion
----------

[Security] Saltless Encoder Interface

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

A new interface for encoders that do not require a user-generated salt (generate their own built-in) as suggested by @stof ([comment](https://github.com/symfony/symfony/pull/21604/files#r101225470)), this will become useful as more password encoders are added in the future (such as symfony/symfony#21604).

Commits
-------

7c4aa0bccb Saltless Encoder Interface
2017-09-27 15:29:25 +02:00
Zan Baldwin
7c4aa0bccb Saltless Encoder Interface
A new interface for all encoders that do not require a user-generated salt.
2017-09-27 12:53:10 +01:00
Christian Flothmann
aa30d04243 [Serializer] throw more specific exceptions 2017-09-27 11:03:29 +02:00
Javier Eguiluz
cb2a1a3786 bug #24237 [WebProfilerBundle] Added missing link to profile token (vtsykun)
This PR was merged into the 3.3 branch.

Discussion
----------

[WebProfilerBundle] Added missing link to profile token

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes, it was on 3.3.6 (before merge https://github.com/symfony/symfony/pull/23676)
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

On v3.3.6 I can open profiles for sub-request on this link
![selection_188](https://user-images.githubusercontent.com/21358010/30518552-dc6a1f72-9b89-11e7-9d2f-d348846d7285.png)

But after 3.3.7 it was replaced by links to the controller. In this pull request was added missing link to the profile
![selection_186](https://user-images.githubusercontent.com/21358010/30518572-7a1420c4-9b8a-11e7-8514-098c4ec2c3d6.png)

Commits
-------

c388b25cbb [WebProfilerBundle] Added missing link to profile token
2017-09-27 09:00:36 +02:00
Fabien Potencier
8483b48de2 bug #24244 TwigBundle exception/deprecation tweaks (ro0NL)
This PR was squashed before being merged into the 3.3 branch (closes #24244).

Discussion
----------

TwigBundle exception/deprecation tweaks

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes/no
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!--highly recommended for new features-->

- 1st commit) if you view a exception in the profiler, there is no logger available. Making the tab useless, disabled state is now triggered at zero log messages. There's a specialized panel here.
- 2nd commit) when an exception occurs this highlights deprecations in the log table outside the profiler with a warning status. This follows the same signal colors in the profiler.
- 3rd commit) hide the default inactive tabs from CSS to avoid scrollbar flickering.
- 4th commit) favors document.DOMContentLoaded over window.load, we dont want to wait for images to be loaded

Further out-of-scope improvements could be;

- From https://github.com/symfony/symfony/pull/24191; i think the logs table should show a direct `View file` link for every error/deprecation/red or yellow line in here. Traversing with `Show context` is tedious.
  - links to file.php for your trigger_error() calls
  - links to config.yml for trigger_error() calls by SF
- From #24151; having the same tooling on both sides is nice
- Events/Translations logs is noise, we have specialized panels for those. To further reduce the overall page size container logs can be moved away too, linked from Configuration and/or Logs. Also see #23247

Commits
-------

1c595fcf48 [TwigBundle][WebProfilerBundle] Switch to DOMContentLoaded event
ea4b0966ab [WebProfilerBundle] Hide inactive tabs from CSS
0c10f97f98 [TwigBundle] Make deprecations scream in logs
03cd9e553b [TwigBundle] Hide logs if unavailable, i.e. webprofiler
2017-09-26 21:35:52 -07:00
Fabien Potencier
3c262bab75 minor #24172 [FrameworkBundle] Enable assets with templates only if the Asset component is installed (hason)
This PR was merged into the 3.4 branch.

Discussion
----------

[FrameworkBundle] Enable assets with templates only if the Asset component is installed

| 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
-------

5bc0b0527e [FrameworkBundle] Enable assets with templates only if the Asset component is installed
2017-09-26 21:32:04 -07:00
Fabien Potencier
beb3fe1b2b bug #24281 [TwigBundle] Remove profiler related scripting (ro0NL, javiereguiluz)
This PR was merged into the 3.3 branch.

Discussion
----------

[TwigBundle] Remove profiler related scripting

| 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-->

For sanity.

Also in case of an exception page we conflict with the profiler scripting/css.

```
Uncaught TypeError: Cannot set property 'className' of null
```

Happens because `Sfjs.createTabs` from the profiler tries to process tabs again, which twig has already done. The code doesnt handle this gracefully.

In case of ajax request (edgy yes) we see the CSS conflicting;

![image](https://user-images.githubusercontent.com/1047696/30712781-7680c8d2-9f0d-11e7-8a6c-27f460c1e780.png)

Note the table borders. Not sure how and if we want to solve this nor what it might affect otherwise; open for now.

Commits
-------

eb520e1e5b Minor reword
02dcdca014 [TwigBundle] Remove profiler related scripting
2017-09-26 16:51:28 -07:00
Fabien Potencier
eb1183111a feature #23471 [Finder] Add a method to check if any results were found (duncan3dc)
This PR was merged into the 3.4 branch.

Discussion
----------

[Finder] Add a method to check if any results were found

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT

If I want to know if any results were found, but I don't want to start trawling through them, I have to do the rather ugly:
```php
$found = false;
foreach ($finder as $thing) {
    $found = true;
    break;
}
if ($found) {
```
This PR enables the much more readable:
```php
if ($finder->found()) {
```

This seemed like an obvious thing to me, so I suspect there might be a reason this doesn't exist already, but I couldn't find any previous discussion. If it'll be accepted then I'll glady create a docs PR

Commits
-------

24dcb5202c Add a method to check if any results were found
2017-09-26 16:22:45 -07:00
Fabien Potencier
08825f8929 feature #23149 [PhpUnitBridge] Added a CoverageListener to enhance the code coverage report (lyrixx)
This PR was squashed before being merged into the 3.4 branch (closes #23149).

Discussion
----------

[PhpUnitBridge] Added a CoverageListener to enhance the code coverage report

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| 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/8416

---

The code coverage computed by PHPUnit is not very accurate by default as it marks a line as tested as soon as it has been executed.
For example, if you have two classes A and B where A is using B and you write test only for the class A then the class B will be marked as tested.

You can fix this issue by adding `@covers A` on top of the class ATest, but it's a bit boring.

This Listener add this annotation on each test if it's applicable:
* If an annotation already exists, we do nothing.
* We try to find the SUT thanks to the Test class name, if it does not exist, we do nothing

---

If you wan to see it in action: https://github.com/lyrixx/phpunit-auto-cover

---

The PR is not finished, I think we could add this listener to symfony itself.

What do you think?

Commits
-------

e17206debd [PhpUnitBridge] Added a CoverageListener to enhance the code coverage report
2017-09-26 16:19:20 -07:00
Grégoire Pineau
e17206debd [PhpUnitBridge] Added a CoverageListener to enhance the code coverage report 2017-09-26 16:19:19 -07:00
Fabien Potencier
8a752c33b9 feature #24318 [SecurityBundle] Deprecate ACL related code (chalasr)
This PR was merged into the 3.4 branch.

Discussion
----------

[SecurityBundle] Deprecate ACL related code

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes/no
| Fixed tickets | replaces #23811
| License       | MIT
| Doc PR        | todo

Needs https://github.com/symfony/acl-bundle/pull/2

Commits
-------

e3b7dc5424 [SecurityBundle] Deprecate ACL related code
2017-09-26 16:03:19 -07:00
Fabien Potencier
efdba489d9 minor #24339 Forward compatibility for the removal of bundle inheritance in 4.0 (fabpot)
This PR was merged into the 3.4 branch.

Discussion
----------

Forward compatibility for the removal of bundle inheritance in 4.0

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Compat layer so that 3.4 and master combinations of framework/twig bundles and http-kernel work together.

Commits
-------

fba7e543d1 added foward compatibility for the removal of bundle inheritance in 4.0
2017-09-26 15:58:28 -07:00
Fabien Potencier
b5103a261f feature #24335 [Security][SecurityBundle] Deprecate the HTTP digest auth (ogizanagi)
This PR was merged into the 3.4 branch.

Discussion
----------

[Security][SecurityBundle] Deprecate the HTTP digest auth

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| 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 | #24325  <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

See https://github.com/symfony/symfony/pull/24336 for the removal PR on master.

Commits
-------

11fe79d77f [Security][SecurityBundle] Deprecate the HTTP digest auth
2017-09-26 15:51:56 -07:00
Robin Chalas
084e49f2ef feature #21951 [Security][Firewall] Passing the newly generated security token to the event during user switching (klandaika)
This PR was merged into the 3.4 branch.

Discussion
----------

[Security][Firewall] Passing the newly generated security token to the event during user switching

Event allows listeners to easily switch out the token if custom token updates are 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        |

Updated SwitchUserEvent to include the generated security Token. Allows the listeners to replace the token with their own (in case an application has some custom logic for token generation). The SwitchUserListener will now use the token returned by the event, so if token was not changed the self generated token will be used. If token was changed in the event then the new token would get used.

Reasons for this feature
--------------------------

In our current project users can have different Role sets depending on which organization they switch to. Our `User->getRoles()` always returns ["ROLE_USER"] and after login user is presented with choice of organizations they want to work in. Based on selected organization roles get updated with then stored token.

Without the change proposed in this PR. The only way we can setup the proper roles during user switch is by replacing `security.authentication.switchuser_listener` service with our own implementation of the listener.

With the proposed change, we can replace the security token with the one having all the roles we require directly inside our listener for `security.switch_user` event that gets thrown by Symfony's `SwitchUserListener`

Commits
-------

4205f1b Passing the newly generated security token to the event during user switching.
2017-09-26 22:15:35 +02:00
VJ
4205f1bc68 Passing the newly generated security token to the event during user switching.
Event allows listeners to easily switch out the token if custom token updates are required
2017-09-26 16:04:50 -04:00
Maxime Steinhausser
6fcb075683 Fix changelog and minor tweak for #23485 2017-09-26 22:01:10 +02:00
Maxime Steinhausser
3ab655ec82 feature #23485 [Config] extracted the xml parsing from XmlUtils::loadFile into XmlUtils::parse (Basster)
This PR was squashed before being merged into the 3.4 branch (closes #23485).

Discussion
----------

[Config] extracted the xml parsing from XmlUtils::loadFile into XmlUtils::parse

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT

I needed the xml parsing for an XML string generated in memory, so I extracted the actual parsing from XmlUtils::loadFile into XmlUtils::load.

Re-opened after I messed some things up in #23482

Commits
-------

7473981c14 [Config] extracted the xml parsing from XmlUtils::loadFile into XmlUtils::parse
2017-09-26 21:49:14 +02:00
Ole Rößner
7473981c14 [Config] extracted the xml parsing from XmlUtils::loadFile into XmlUtils::parse 2017-09-26 21:48:48 +02:00
Maxime Steinhausser
11fe79d77f [Security][SecurityBundle] Deprecate the HTTP digest auth 2017-09-26 20:29:06 +02:00
Fabien Potencier
fba7e543d1 added foward compatibility for the removal of bundle inheritance in 4.0 2017-09-26 19:25:46 +02:00
Maxime Steinhausser
ec8edeeb29 feature #22890 [HttpKernel] Add ability to configure catching exceptions for Client (kbond)
This PR was merged into the 3.4 branch.

Discussion
----------

[HttpKernel] Add ability to configure catching exceptions for Client

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | todo

Debugging exceptions in functional tests is difficult as you need to look at the logs to see which exception was thrown. Disabling catching of exceptions in the client would allow the exception to bubble up to phpunit  and make it easier to see what exception was thrown.

Commits
-------

4812e60 add ability to configure catching exceptions
2017-09-26 17:48:51 +02:00
Tim Jabs
ab47c7878e Added improvement for accuracy in MoneyToLocalizedStringTransformer. 2017-09-26 17:19:17 +02:00
Craig Duncan
24dcb5202c Add a method to check if any results were found 2017-09-26 15:59:44 +01:00
Kevin Bond
4812e6054c
add ability to configure catching exceptions 2017-09-26 10:46:55 -04:00
Nicolas Grekas
07f79737bc minor #22589 Extract method refactoring for ResourceCheckerConfigCache (mpdude)
This PR was squashed before being merged into the 3.4 branch (closes #22589).

Discussion
----------

Extract method refactoring for ResourceCheckerConfigCache

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Improves code readability.

Commits
-------

685c353 Extract method refactoring for ResourceCheckerConfigCache
2017-09-26 16:36:06 +02:00
Matthias Pigulla
685c3538fb Extract method refactoring for ResourceCheckerConfigCache 2017-09-26 16:36:04 +02:00
Tobias Schultze
bc8430418b feature #24239 [HttpFoundation] Deprecate compatibility with PHP <5.4 sessions (afurculita)
This PR was squashed before being merged into the 3.4 branch (closes #24239).

Discussion
----------

[HttpFoundation] Deprecate compatibility with PHP <5.4 sessions

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

This PR removes functionality added in Symfony 2.1 as a compatibility layer with sessions from PHP <5.4.

- [x] Fix tests

Commits
-------

3deb3940ab [HttpFoundation] Deprecate compatibility with PHP <5.4 sessions
2017-09-26 14:23:54 +02:00
Alexandru Furculita
3deb3940ab [HttpFoundation] Deprecate compatibility with PHP <5.4 sessions 2017-09-26 14:23:43 +02:00
Robin Chalas
e3b7dc5424 [SecurityBundle] Deprecate ACL related code 2017-09-26 13:11:38 +02:00
Robin Chalas
477a24dff9 feature #23882 [Security] Deprecated not being logged out after user change (iltar)
This PR was squashed before being merged into the 3.4 branch (closes #23882).

Discussion
----------

[Security] Deprecated not being logged out after user change

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | #17023
| License       | MIT
| Doc PR        | ~

This PR is an alternative approach to #19033. Due to a behavioral change that could break a lot of applications and websites, I've decided to trigger a deprecation instead of actually changing the behavior as that can be done for 4.0.

Whenever a user object is considered changed (`AbstractToken::hasUserChanged`) when setting a new user object after refreshing, it will now throw a deprecation, paving the way for a behavioral change in 4.0. The idea is that in 4.0 Symfony will simply trigger a logout when this case is encountered.

Commits
-------

22f525b [Security] Deprecated not being logged out after user change
2017-09-26 13:05:27 +02:00