Commit Graph

32388 Commits

Author SHA1 Message Date
Robin Chalas
b9fc357d1c Fix merge 2017-08-29 23:15:51 +02:00
Fabien Potencier
2e111b3cca Merge branch '3.3' into 3.4
* 3.3: (27 commits)
  Always require symfony/polyfill-apcu to provide APCuIterator everywhere
  bumped Symfony version to 3.3.9
  updated VERSION for 3.3.8
  updated CHANGELOG for 3.3.8
  [DI] Fix tracking env var placeholders nested in object graphs
  bumped Symfony version to 3.3.8
  updated VERSION for 3.3.7
  updated CHANGELOG for 3.3.7
  [DI] Fix tracking env vars when merging configs (bis)
  removed obsolete comment
  install PHPUnit 6 on PHP 7.2
  [Cache] Use zend.detect_unicode instead of zend.multibyte
  Fix case sensitive typo in use class name
  [VarDumper] Enhance docblock to tell about AbstractDumper::dumpLine(-1)
  [Debug] Remove false-positive check in DebugClassLoader
  [Validator] Fix use of GroupSequenceProvider in child classes
  Change number PHPDoc type to int|float
  [Cache] Workaround zend.detect_unicode + zend.multibyte
  [VarDumper] Strengthen dumped JS
  [VarDumper] Strengthen dumped JS
  ...
2017-08-29 14:00:42 -07:00
Fabien Potencier
dda57e6e21 feature #22543 [Lock] Expose an expiringDate and isExpired method in Lock (jderusse)
This PR was squashed before being merged into the 3.4 branch (closes #22543).

Discussion
----------

[Lock] Expose an expiringDate and isExpired method in Lock

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

This PR store the expiration date of the lock in the key and exposes public method to let the user know the state of the Lock expiration.

Commits
-------

279430800e [Lock] Expose an expiringDate and isExpired method in Lock
2017-08-29 13:57:32 -07:00
Jérémy Derussé
279430800e [Lock] Expose an expiringDate and isExpired method in Lock 2017-08-29 13:57:28 -07:00
Fabien Potencier
173b7473d3 feature #23667 [Translation] Create an TranslationReaderInterface and move TranslationLoader to TranslationComponent (Nyholm)
This PR was merged into the 3.4 branch.

Discussion
----------

[Translation] Create an TranslationReaderInterface and move TranslationLoader to TranslationComponent

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

Create an interface for TranslationLoader. I put this in the Translation component even though the TranslationLoader implementation is in the FrameworkBundle. (Here is a PR moving the TranslationLoader to the Translation component: #23666)

We need this in PHP-translation. We currently have to rewrite things in strange mannar like: https://github.com/php-translation/symfony-storage/blob/0.2.2/src/FileStorage.php#L62-L64

Commits
-------

5bc50da677 Create an interface for TranslationReader and moved TranslationLoader to Translation component
2017-08-29 13:53:50 -07:00
Fabien Potencier
ec7a2b14ca bug #24011 [Cache] Always require symfony/polyfill-apcu to provide APCuIterator everywhere (guillaumelecerf)
This PR was merged into the 3.3 branch.

Discussion
----------

[Cache] Always require symfony/polyfill-apcu to provide APCuIterator everywhere

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

**TL;DR: when APCuIterator is not available (i.e. PHP 5.6 + APCu 4.0.7), the APC cache handling is broken.**

When [the app initializes](https://github.com/symfony/symfony/blob/master/src/Symfony/Bundle/FrameworkBundle/Resources/config/cache.xml#L31) one of [the APC caches](https://github.com/symfony/symfony/blob/master/src/Symfony/Bundle/FrameworkBundle/Resources/config/cache.xml#L14-L28), it tries to [retrieve its namespace flag key](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Cache/Traits/ApcuTrait.php#L42). If it can't, [it clears its namespaced cache](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Cache/Traits/ApcuTrait.php#L43) and [adds its flag key back](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Cache/Traits/ApcuTrait.php#L44).
But [when APCuIterator is not usable](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Cache/Traits/ApcuTrait.php#L74), **the app [flushes the whole cache each time](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Cache/Traits/ApcuTrait.php#L76)**, preventing all the APC caches to retrieve their own flag key, resulting in a **perpetual full APC cache flush**.

TODO:
- [x] add test => https://travis-ci.org/symfony/symfony/jobs/269383629#L3334

See https://github.com/symfony/symfony/pull/24008

Commits
-------

9d444421ea Always require symfony/polyfill-apcu to provide APCuIterator everywhere
2017-08-29 13:50:21 -07:00
Nicolas Grekas
d00ac8adef [VarDumper] fix DateCasterTest 2017-08-29 18:16:36 +02:00
Nicolas Grekas
cba3393f9d minor #24023 [VarDumper] Fix segfault in period caster (maidmaid)
This PR was merged into the 3.4 branch.

Discussion
----------

[VarDumper] Fix segfault in period caster

| 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/23668#issuecomment-325685087
| License       | MIT
| Doc PR        | /

[This segfault](https://bugs.php.net/bug.php?id=71635) was fixed in [5.6.20](http://www.php.net/ChangeLog-5.php#5.6.20) and in [7.0.5](http://www.php.net/ChangeLog-7.php#7.0.5).

Issue in action here: https://3v4l.org/DhOdT#v565

Commits
-------

d84e9c8 Fix segfault in period caster
2017-08-29 18:08:59 +02:00
Nicolas Grekas
3d5172aa3e feature #24024 [config] Add ability to deprecate a node (sanpii)
This PR was merged into the 3.4 branch.

Discussion
----------

[config] Add ability to deprecate a node

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

This is #22382 on 3.4

Commits
-------

a00a4ff [config] Add ability to deprecate a node
2017-08-29 18:06:44 +02:00
Sanpi
a00a4ffb04 [config] Add ability to deprecate a node 2017-08-29 17:54:12 +02:00
Fabien Potencier
d4e8166927 feature #22382 [config] Add abbitily to deprecate a node (Nyholm, fabpot, sanpii)
This PR was merged into the 3.4-dev branch.

Discussion
----------

[config] Add abbitily to deprecate a node

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

For BC breaks, I don’t know if modifying the Xml and Yaml dumper output is considering as a BC break (it’s just a comment).

Commits
-------

31d2250f4c [config] Add abbitily to deprecate a node
3b6442f8b2 feature #23947 [Translation] Adding the ability do load <notes> in xliff2.0 (Nyholm)
b0cdb53d67 [Translation] Adding the ability do load <notes> in xliff2.0
2017-08-29 17:48:44 +02:00
Dany Maillard
d84e9c8171 Fix segfault in period caster 2017-08-29 17:37:07 +02:00
Tobias Nyholm
5bc50da677
Create an interface for TranslationReader and moved TranslationLoader to Translation component 2017-08-29 16:37:52 +02:00
Nicolas Grekas
660feccb20 feature #23668 [VarDumper] Add period caster (maidmaid)
This PR was merged into the 3.4 branch.

Discussion
----------

[VarDumper] Add period caster

| 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/pull/23591#discussion_r128307341
| License       | MIT
| Doc PR        | /

Result:

![](https://user-images.githubusercontent.com/4578773/29788181-fce3eb32-8c31-11e7-9da4-72c038d5a14e.png)

Commits
-------

4c4c398 Add period caster
2017-08-29 16:18:55 +02:00
Guillaume LECERF
9d444421ea Always require symfony/polyfill-apcu to provide APCuIterator everywhere 2017-08-29 16:10:37 +02:00
Nicolas Grekas
0096738b52 feature #23991 [DI] Improve psr4-based service discovery (alternative implementation) (kbond)
This PR was merged into the 3.4 branch.

Discussion
----------

[DI] Improve psr4-based service discovery (alternative implementation)

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

This is an alternative to #23986. It is simpler and doesn't require a second glob in the service id. This adds a `namespace` option. It is optional and if it isn't used, then it falls back to using the service id (current behaviour).

As stof mentions in https://github.com/symfony/symfony/issues/22397#issuecomment-324972955, it is consistent with the xml loader.

With this feature, you can define your services like this:

```yaml
services:
    command_handlers:
        namespace: App\Domain\
        resource: ../../src/Domain/*/CommandHandler
        tags: [command_handler]

    event_subscribers:
        namespace: App\Domain\
        resource: ../../src/Domain/*/EventSubscriber
        tags: [event_subscriber]
```

ping @stof, @nicolas-grekas

Commits
-------

00d7f6f [DI] improve psr4-based service discovery with namespace option
2017-08-29 16:04:03 +02:00
Nicolas Grekas
9f60314e64 minor #24004 [Lock] Fix some tests that require pcntl_sigwaitinfo() function (javiereguiluz)
This PR was squashed before being merged into the 3.4 branch (closes #24004).

Discussion
----------

[Lock] Fix some tests that require pcntl_sigwaitinfo() function

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

Commits
-------

a8d72e2 [Lock] Fix some tests that require pcntl_sigwaitinfo() function
2017-08-29 16:00:09 +02:00
Javier Eguiluz
a8d72e260f [Lock] Fix some tests that require pcntl_sigwaitinfo() function 2017-08-29 16:00:07 +02:00
Fabien Potencier
9280ca429e bumped Symfony version to 3.3.9 2017-08-28 15:49:36 -07:00
Fabien Potencier
645d24a119 Merge pull request #24017 from fabpot/release-3.3.8
released v3.3.8
2017-08-28 15:35:20 -07:00
Fabien Potencier
bad5b6293d updated VERSION for 3.3.8 2017-08-28 15:35:03 -07:00
Fabien Potencier
04e7d44d12 updated CHANGELOG for 3.3.8 2017-08-28 15:34:58 -07:00
Fabien Potencier
64bcf6d0fb bug #24016 [DI] Fix tracking env var placeholders nested in object graphs (nicolas-grekas)
This PR was merged into the 3.3 branch.

Discussion
----------

[DI] Fix tracking env var placeholders nested in object graphs

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

Commits
-------

a8397cf1c7 [DI] Fix tracking env var placeholders nested in object graphs
2017-08-28 15:31:00 -07:00
Nicolas Grekas
a8397cf1c7 [DI] Fix tracking env var placeholders nested in object graphs 2017-08-29 00:20:37 +02:00
Fabien Potencier
0b46166174 bumped Symfony version to 3.3.8 2017-08-28 13:30:14 -07:00
Fabien Potencier
d5461f867f Merge pull request #24013 from fabpot/release-3.3.7
released v3.3.7
2017-08-28 13:18:27 -07:00
Fabien Potencier
8a33ecb058 updated VERSION for 3.3.7 2017-08-28 12:34:14 -07:00
Fabien Potencier
2a7cf1993c updated CHANGELOG for 3.3.7 2017-08-28 12:34:07 -07:00
Dany Maillard
4c4c3987fd Add period caster 2017-08-28 20:44:17 +02:00
Fabien Potencier
b12109d884 bug #24009 [DI] Fix tracking env vars when merging configs (bis) (nicolas-grekas)
This PR was merged into the 3.3 branch.

Discussion
----------

[DI] Fix tracking env vars when merging configs (bis)

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

Commits
-------

baaff20f4a [DI] Fix tracking env vars when merging configs (bis)
2017-08-28 11:35:09 -07:00
Kevin Bond
00d7f6fa71
[DI] improve psr4-based service discovery with namespace option 2017-08-28 12:51:31 -04:00
Nicolas Grekas
baaff20f4a [DI] Fix tracking env vars when merging configs (bis) 2017-08-28 17:49:50 +02:00
Fabien Potencier
2230e31727 removed obsolete comment 2017-08-28 04:33:29 -07:00
Fabien Potencier
faa83282bc bug #23952 [PhpUnitBridge] install PHPUnit 6 on PHP 7.2 (xabbuh)
This PR was merged into the 3.3 branch.

Discussion
----------

[PhpUnitBridge] install PHPUnit 6 on PHP 7.2

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

Commits
-------

30336ead94 install PHPUnit 6 on PHP 7.2
2017-08-28 04:32:48 -07:00
Christian Flothmann
30336ead94 install PHPUnit 6 on PHP 7.2 2017-08-28 12:44:05 +02:00
Nicolas Grekas
f47626c3c4 minor #24003 [Cache] Use zend.detect_unicode instead of zend.multibyte (nicolas-grekas)
This PR was merged into the 3.3 branch.

Discussion
----------

[Cache] Use zend.detect_unicode instead of zend.multibyte

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

Verified.

Commits
-------

e600cd8 [Cache] Use zend.detect_unicode instead of zend.multibyte
2017-08-28 10:28:26 +02:00
Nicolas Grekas
e600cd8647 [Cache] Use zend.detect_unicode instead of zend.multibyte 2017-08-28 10:20:24 +02:00
Fabien Potencier
726c567d14 Merge branch '2.8' into 3.3
* 2.8:
  [VarDumper] Enhance docblock to tell about AbstractDumper::dumpLine(-1)
  [Debug] Remove false-positive check in DebugClassLoader
  [Validator] Fix use of GroupSequenceProvider in child classes
  Change number PHPDoc type to int|float
  [VarDumper] Strengthen dumped JS
  [travis] Add timing info
  [Validator] Fix Greek translation
  [Console] Initialize lazily to render exceptions properly
  [Validator] Add a property tag for File::$maxSize
2017-08-27 07:52:21 -07:00
Fabien Potencier
4173f1389e minor #24000 [Translation] Fix <note> is interpreted as a tag in CHANGELOG (ogizanagi)
This PR was merged into the 3.4 branch.

Discussion
----------

[Translation] Fix <note> is interpreted as a tag in CHANGELOG

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

... and is removed when rendering the markdown. Put it in a code span instead.

Commits
-------

cc9fd5967d [Translation] Fix <note> is interpreted as a tag in CHANGELOG
2017-08-27 07:44:06 -07:00
Fabien Potencier
a2d80cafb1 minor #24002 Fix case sensitive typo in use class name (PhilETaylor)
This PR was merged into the 3.3 branch.

Discussion
----------

Fix case sensitive typo in use class name

closes #24001

Change is simple typo: Parameterbag = ParameterBag

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

Fixes this:

`
  [RuntimeException]
  An error occurred when executing the "'cache:clear --no-warmup'" command:
  Fatal error: Uncaught RuntimeException: Case mismatch between loaded and declared class names: "Symfony\Component\DependencyInjection\Parameterbag\EnvPlaceholderParameterBag" v
  s "Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag". in /Users/phil/Sites/maintain.myjoomla.com/vendor/symfony/symfony/src/Symfony/Component/Debug
  /DebugClassLoader.php:165
`

Commits
-------

6fe9072c42 Fix case sensitive typo in use class name
2017-08-27 07:43:21 -07:00
Fabien Potencier
8a38f887cb bug #23985 [Cache] Workaround zend.detect_unicode + zend.multibyte (nicolas-grekas)
This PR was merged into the 3.3 branch.

Discussion
----------

[Cache] Workaround zend.detect_unicode + zend.multibyte

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

ping @patrickvane

Commits
-------

1cab07ebee [Cache] Workaround zend.detect_unicode + zend.multibyte
2017-08-27 07:31:02 -07:00
Fabien Potencier
d3692cefac Merge branch '2.7' into 2.8
* 2.7:
  [VarDumper] Enhance docblock to tell about AbstractDumper::dumpLine(-1)
  [Debug] Remove false-positive check in DebugClassLoader
  [Validator] Fix use of GroupSequenceProvider in child classes
  Change number PHPDoc type to int|float
  [VarDumper] Strengthen dumped JS
  [travis] Add timing info
  [Validator] Fix Greek translation
  [Console] Initialize lazily to render exceptions properly
  [Validator] Add a property tag for File::$maxSize
2017-08-27 07:29:03 -07:00
Fabien Potencier
c6ffdcf9dd minor #23999 [VarDumper] Enhance docblock to tell about AbstractDumper::dumpLine(-1) (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[VarDumper] Enhance docblock to tell about AbstractDumper::dumpLine(-1)

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

Commits
-------

0164038998 [VarDumper] Enhance docblock to tell about AbstractDumper::dumpLine(-1)
2017-08-27 07:26:20 -07:00
Fabien Potencier
56987eabd1 bug #23989 [Debug] Remove false-positive check in DebugClassLoader (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[Debug] Remove false-positive check in DebugClassLoader

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

In some edge case situations, DebugClassLoader generates false-positives (see linked issue, ping @gharlan).

Commits
-------

466da3fd63 [Debug] Remove false-positive check in DebugClassLoader
2017-08-27 07:20:32 -07:00
Phil Taylor
6fe9072c42 Fix case sensitive typo in use class name
closes #24001

Simple typo fix
2017-08-27 14:23:17 +01:00
Maxime Steinhausser
cc9fd5967d [Translation] Fix <note> is interpreted as a tag in CHANGELOG 2017-08-27 10:55:51 +02:00
Nicolas Grekas
0164038998 [VarDumper] Enhance docblock to tell about AbstractDumper::dumpLine(-1) 2017-08-27 10:38:33 +02:00
Nicolas Grekas
466da3fd63 [Debug] Remove false-positive check in DebugClassLoader 2017-08-27 10:27:28 +02:00
Fabien Potencier
ebd14ee67f bug #23983 [VarDumper] Strengthen dumped JS (nicolas-grekas)
This PR was merged into the 3.3 branch.

Discussion
----------

[VarDumper] Strengthen dumped JS

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

3.3 part of #23982

Commits
-------

5e05fc958f [VarDumper] Strengthen dumped JS
2017-08-26 06:19:07 -07:00
Fabien Potencier
c8966640bd bug #23982 [VarDumper] Strengthen dumped JS (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[VarDumper] Strengthen dumped JS

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

Commits
-------

5c1bd10017 [VarDumper] Strengthen dumped JS
2017-08-26 06:17:11 -07:00