Commit Graph

37189 Commits

Author SHA1 Message Date
Fabien Potencier
72fb10057f bumped Symfony version to 4.1.0 2018-05-21 16:30:52 +02:00
Fabien Potencier
b5608f4bd8
Merge pull request #27331 from fabpot/release-4.1.0-BETA2
released v4.1.0-BETA2
2018-05-21 16:28:07 +02:00
Fabien Potencier
ae8513b01c updated VERSION for 4.1.0-BETA2 2018-05-21 16:27:45 +02:00
Fabien Potencier
c577609a66 updated CHANGELOG for 4.1.0-BETA2 2018-05-21 16:27:36 +02:00
Fabien Potencier
47529b51e4 bumped Symfony version to 4.0.11 2018-05-21 16:04:59 +02:00
Fabien Potencier
bcb589c901
Merge pull request #27330 from fabpot/release-4.0.10
released v4.0.10
2018-05-21 16:02:48 +02:00
Fabien Potencier
1313ba3f46 updated VERSION for 4.0.10 2018-05-21 16:02:31 +02:00
Fabien Potencier
c5dc846806 updated CHANGELOG for 4.0.10 2018-05-21 16:02:26 +02:00
Fabien Potencier
52270d1e5a bumped Symfony version to 3.4.11 2018-05-21 16:00:59 +02:00
Fabien Potencier
816bf5030e
Merge pull request #27329 from fabpot/release-3.4.10
released v3.4.10
2018-05-21 15:44:23 +02:00
Fabien Potencier
7be0b084a5 updated VERSION for 3.4.10 2018-05-21 15:44:03 +02:00
Fabien Potencier
56c711fd6e updated CHANGELOG for 3.4.10 2018-05-21 15:43:55 +02:00
Fabien Potencier
6d4de55666 bumped Symfony version to 2.8.41 2018-05-21 15:43:22 +02:00
Fabien Potencier
901a4fb385
Merge pull request #27328 from fabpot/release-2.8.40
released v2.8.40
2018-05-21 15:17:42 +02:00
Fabien Potencier
ca80b59dc1 updated VERSION for 2.8.40 2018-05-21 15:17:29 +02:00
Fabien Potencier
b9ff0b0124 updated CHANGELOG for 2.8.40 2018-05-21 15:17:24 +02:00
Fabien Potencier
84bba75ad1 bumped Symfony version to 2.7.48 2018-05-21 13:56:57 +02:00
Fabien Potencier
f629de3af2
Merge pull request #27327 from fabpot/release-2.7.47
released v2.7.47
2018-05-21 13:48:51 +02:00
Fabien Potencier
e55c38be00 updated VERSION for 2.7.47 2018-05-21 13:48:33 +02:00
Fabien Potencier
fb1aea810e update CONTRIBUTORS for 2.7.47 2018-05-21 13:48:28 +02:00
Fabien Potencier
e559215fcf updated CHANGELOG for 2.7.47 2018-05-21 13:47:41 +02:00
Fabien Potencier
440bd7ea50 fixed test 2018-05-21 13:44:24 +02:00
Fabien Potencier
021531b55f Merge branch '4.1'
* 4.1:
  fixed bad merge
2018-05-21 13:08:13 +02:00
Fabien Potencier
7cb6e61f77 Merge branch '4.0' into 4.1
* 4.0:
  fixed bad merge
2018-05-21 13:08:00 +02:00
Fabien Potencier
dff61b82ff fixed bad merge 2018-05-21 13:07:53 +02:00
Fabien Potencier
ea77ef1f76 Merge branch '4.1'
* 4.1:
  removed obsolete tests
2018-05-21 12:59:24 +02:00
Fabien Potencier
389092a6a9 Merge branch '4.0' into 4.1
* 4.0:
  removed obsolete tests
2018-05-21 12:59:05 +02:00
Fabien Potencier
2ce15f9179 removed obsolete tests 2018-05-21 12:58:57 +02:00
Fabien Potencier
00f25ee8f7 Merge branch '4.1'
* 4.1:
  fixed bad merge
2018-05-21 12:48:51 +02:00
Fabien Potencier
f9183db863 Merge branch '4.0' into 4.1
* 4.0:
  fixed bad merge
2018-05-21 12:48:43 +02:00
Fabien Potencier
f2419ddda6 fixed bad merge 2018-05-21 12:48:24 +02:00
Fabien Potencier
1f4100d635 Merge branch '4.1'
* 4.1:
  Supress deprecation notices thrown when getting private servies from container in tests
  Uses `protected` for test functions
  [Messenger] Allow to scope handlers per bus
  do not mock the session in token storage tests
  [DependencyInjection] resolve array env vars
  Add Occitan plural rule
  Fix security/* cross-dependencies
  [Messenger] implement several senders using a ChainSender
  [Lock] Skip test if posix extension is not installed
  fix bug when imported routes are prefixed
  [DI] Allow defining bindings on ChildDefinition
  use strict compare in url validator
  Disallow illegal characters like "." in session.name
  [HttpKernel] do file_exists() check instead of silent notice
  Select alternatives on missing receiver arg or typo
  fix rounding from string
2018-05-21 12:10:22 +02:00
Fabien Potencier
af4372220c Merge branch '4.0' into 4.1
* 4.0:
  do not mock the session in token storage tests
  [DependencyInjection] resolve array env vars
  Add Occitan plural rule
  Fix security/* cross-dependencies
  [Lock] Skip test if posix extension is not installed
  [DI] Allow defining bindings on ChildDefinition
  use strict compare in url validator
  Disallow illegal characters like "." in session.name
  [HttpKernel] do file_exists() check instead of silent notice
  fix rounding from string
2018-05-21 12:10:11 +02:00
Fabien Potencier
4d8a71d321 Merge branch '3.4' into 4.0
* 3.4:
  do not mock the session in token storage tests
  [DependencyInjection] resolve array env vars
  Add Occitan plural rule
  Fix security/* cross-dependencies
  [Lock] Skip test if posix extension is not installed
  [DI] Allow defining bindings on ChildDefinition
  use strict compare in url validator
  Disallow illegal characters like "." in session.name
  [HttpKernel] do file_exists() check instead of silent notice
  fix rounding from string
2018-05-21 12:09:47 +02:00
Fabien Potencier
793d1fe71a Merge branch '2.8' into 3.4
* 2.8:
  do not mock the session in token storage tests
  Add Occitan plural rule
  Fix security/* cross-dependencies
  Disallow illegal characters like "." in session.name
  fix rounding from string
2018-05-21 12:06:52 +02:00
Fabien Potencier
e336711cd9 Merge branch '2.7' into 2.8
* 2.7:
  do not mock the session in token storage tests
  Add Occitan plural rule
  Disallow illegal characters like "." in session.name
  fix rounding from string
2018-05-21 11:59:10 +02:00
Fabien Potencier
ec6d46c360 feature #27305 [Security/Core] Add "is_granted()" to security expressions, deprecate "has_role()" (nicolas-grekas)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[Security/Core] Add "is_granted()" to security expressions, deprecate "has_role()"

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

Because `has_role()` doesn't use the auth checker, it is confusing. Let's move `is_granted()` to core (it's provided by SensioFrameworkExtraBundle / ApiPlatform for now.

Commits
-------

9dbf399247 [Security/Core] Add "is_granted()" to security expressions, deprecate "has_role()"
2018-05-21 11:40:07 +02:00
Nicolas Grekas
70c70e2d9f bug #27312 Supress deprecation notices thrown when getting private servies from container in tests (arderyp)
This PR was submitted for the master branch but it was squashed and merged into the 4.1 branch instead (closes #27312).

Discussion
----------

Supress deprecation notices thrown when getting private servies from container in tests

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

This is my first attempt at fixing #27037.

This approach works for me, and I believe it will work globally, but I am not entirely sure if it is the "right" way to do this.  Its not that I think it's the "wrong" way to do it, its just that the `phpunit-bridge` code structure is not the type of code structure that I'm used to, and I'm still new to this project, so I don't know all of the ins and outs, or if there might be a more ideal place to inject the logic we want.

Also, I think my code may be a bit redundant, and I was hoping to get feedback on that.  @nicolas-grekas  (or anyone else), do you think it is safe to simply check if the deprecation message contains the substring ` service is private, getting it from the container...`? if so, then I think we can simply get rid of my `$isNoticeForContainerGetUsage` bit altogether.  If I am understanding things properly, `$isNoticeForContainerGetUsage` will always be true if `$isPrivateServiceNotice` is true, thus we can safely remove the former (as the later is more intuitive, IMO).

The last thing I wanted to confirm was my interpretation of the stack trace, as detailed in my code comment. If the bit after `NOTE` is not correct, this code might not be a proper solution.  I tested various contexts where the error should be suppressed (from within tests) and also where it should not (from within controllers, etc), which is what I based my `NOTE` comment on.

Commits
-------

00603bf010 Supress deprecation notices thrown when getting private servies from container in tests
2018-05-21 11:19:02 +02:00
Philip Ardery
00603bf010 Supress deprecation notices thrown when getting private servies from container in tests 2018-05-21 11:18:50 +02:00
Samuel ROZE
7497ad4a68 feature #27275 [Messenger] Allow to scope handlers per bus (ogizanagi, sroze)
This PR was merged into the 4.1 branch.

Discussion
----------

[Messenger] Allow to scope handlers per bus

| Q             | A
| ------------- | ---
| Branch?       | 4.1 <!-- see below -->
| 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   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | todo

<img width="970" alt="screenshot 2018-05-15 a 18 34 11" src="https://user-images.githubusercontent.com/2211145/40070551-b36d1f50-586e-11e8-8a44-c6a1503312dd.PNG">

This prevents from dispatching a message in the wrong bus. It works especially great with PSR-4 discovery in DI:

```yaml
command_handlers:
    namespace: App\Message\
    resource: '%kernel.project_dir%/src/Message/*CommandHandler.php'
    tags:
        - { name: messenger.message_handler, bus: command_bus }

query_handlers:
    namespace: App\Message\
    resource: '%kernel.project_dir%/src/Message/*QueryHandler.php'
    tags:
        - { name: messenger.message_handler, bus: query_bus }
```

<details>

<summary>(or in some layered architecture)</summary>

```yaml
command_handlers:
    namespace: App\Application\
    resource: '%kernel.project_dir%/src/Application/**/Handler/*CommandHandler.php'
    tags:
        - { name: messenger.message_handler, bus: command_bus }

query_handlers:
    namespace: App\Application\
    resource: '%kernel.project_dir%/src/Application/**/Handler/*QueryHandler.php'
    tags:
        - { name: messenger.message_handler, bus: query_bus }
```

</details>

---
It also updates (and add tests for) the `DebugCommand`, so we can inspect easily where is supposed to be handled each message.
It's totally optional, and if the bus isn't provided, then it stays available in every bus.

Commits
-------

fd810cdee0 Uses `protected` for test functions
9d658e915e [Messenger] Allow to scope handlers per bus
2018-05-20 10:49:44 +01:00
Samuel ROZE
fd810cdee0 Uses protected for test functions 2018-05-20 10:26:34 +01:00
Maxime Steinhausser
9d658e915e [Messenger] Allow to scope handlers per bus 2018-05-19 12:07:07 +02:00
Robin Chalas
1c520a920f minor #27310 [Security] do not mock the session in token storage tests (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[Security] do not mock the session in token storage tests

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

Commits
-------

919f93d do not mock the session in token storage tests
2018-05-19 06:09:13 +02:00
Christian Flothmann
919f93d91c do not mock the session in token storage tests 2018-05-18 20:00:42 +02:00
Nicolas Grekas
9dbf399247 [Security/Core] Add "is_granted()" to security expressions, deprecate "has_role()" 2018-05-18 17:34:07 +02:00
Nicolas Grekas
589ff697f4 [Cache] Add [Taggable]CacheInterface, the easiest way to use a cache 2018-05-18 14:27:36 +02:00
Fabien Potencier
2ae7ad9fe1 updated CHANGELOG 2018-05-18 08:10:24 +02:00
Fabien Potencier
07cfa93fc1 removed unneeded private methods 2018-05-18 08:08:04 +02:00
Fabien Potencier
ca050f6cc3 feature #27069 [LDAP] Add "applyOperations" method to EntryManager (mablae)
This PR was merged into the 4.2-dev branch.

Discussion
----------

[LDAP] Add "applyOperations" method to EntryManager

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

This PR adds a new method called `applyOperations` to the LDAP `EntryManager` class.
Internally it is mapping the new `UpdateOperation` object to the `ldap_modify_batch` method.

Tests green against openldap.

Thanks for any feedback.

Todo:

  * [x] Add Docs PR

Commits
-------

8fc09c73c6 Add applyOperations batch method to EntryManager
2018-05-18 08:06:16 +02:00
Fabien Potencier
dd2c4c5a70 minor #27249 [HttpKernel] do file_exists() check instead of silent notice (nicolas-grekas)
This PR was merged into the 3.4 branch.

Discussion
----------

[HttpKernel] do file_exists() check instead of silent notice

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

Commits
-------

f8cde70ba1 [HttpKernel] do file_exists() check instead of silent notice
2018-05-18 04:03:52 +02:00