Commit Graph

31680 Commits

Author SHA1 Message Date
Fabien Potencier
7787343c3d feature #23332 [Yaml] fix the displayed line number (fabpot, xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

[Yaml] fix the displayed line number

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

First, this PR backports #23294 to the `3.4` branch.

Secondly, `getRealCurrentLineNb()` returns line numbers index by 0 (as they serve as array indexes internally). I removed the `getLastLineNumberBeforeDeprecation()` method added in #23294 as we can just expose the already existing `getRealCurrentLineNb()` method.

Commits
-------

a2ae6bf745 [Yaml] fix the displayed line number
1baac5a74f feature #23294 [Yaml][Lint] Add line numbers to JSON output. (WybrenKoelmans)
2017-06-30 13:20:19 +02:00
Kévin Dunglas
e0c5040398
[PropertyAccess] Fix TypeError discard 2017-06-30 11:24:55 +02:00
Christian Flothmann
a2ae6bf745 [Yaml] fix the displayed line number
`getRealCurrentLineNb()` returns line numbers index by 0 (as they serve
as array indexes internally).
2017-06-30 11:07:51 +02:00
Fabien Potencier
1baac5a74f feature #23294 [Yaml][Lint] Add line numbers to JSON output. (WybrenKoelmans)
This PR was merged into the 4.0-dev branch.

Discussion
----------

[Yaml][Lint] Add line numbers to JSON output.

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

- [ ] Run tests?
- [ ] Check if it will break BC?
- [ ] Update changelog?

The JSON output is not very useful for me without the line number. I don't want to have to parse it from the message.

Is this the right way of doing it?

With PR:
```
[
    {
        "file": "",
        "line": 13,
        "valid": false,
        "message": "Unable to parse at line 13 (near \"sdf \")."
    }
]
```

Before:
```
[
    {
        "file": "",
        "valid": false,
        "message": "Unable to parse at line 13 (near \"sdf \")."
    }
]
```

Commits
-------

c6d19b1976 [Yaml][Twig][Lint] Added line numbers to JSON output.
2017-06-30 11:07:28 +02:00
Maxime Steinhausser
2de59a7381 [Validator] Throw exception on Comparison constraints null options 2017-06-30 08:56:32 +02:00
Maxime Steinhausser
6cd188bd72 [FrameworkBundle] Display a proper warning on cache:clear without the --no-warmup option 2017-06-29 20:05:44 +02:00
Robin Chalas
8014b38055 [Security] Fix Firewall ExceptionListener priority 2017-06-28 17:08:40 +02:00
Julien Pauli
b31ebae4cb Allow * to bind all interfaces (as INADDR_ANY) 2017-06-28 13:38:39 +02:00
Pedro Magalhães
65d89ec224 Identify tty tests in Component/Process 2017-06-27 18:14:10 +02:00
Grégoire Pineau
25ab3390d3 bug #23299 [Workflow] Added more events to the announce function (Nyholm)
This PR was submitted for the master branch but it was merged into the 3.2 branch instead (closes #23299).

Discussion
----------

[Workflow] Added more events to the announce function

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

This PR will fix #23275

The documentation states that we dispatch events `workflow.announce` and `workflow.[name].announce`. It was me who wrongly added it to the docs... sorry about that.

We could either: Change the docs or add these events. I choose to add these event to the source since the same events are dispatched for "guard", "leave", "transition", "enter" and "entered".

Commits
-------

c5042f35e1 [Workflow] Added more events to the announce function
2017-06-26 14:40:45 +02:00
Tobias Nyholm
c5042f35e1 [Workflow] Added more events to the announce function 2017-06-26 14:40:44 +02:00
Maxime Steinhausser
e9e1534cde [Validator] Remove property path suggestion for using the Expression validator 2017-06-25 18:46:33 +02:00
Maxime Steinhausser
9f9697a57d [WebProfilerBundle] Fix css trick used for offsetting html anchor from fixed header 2017-06-25 18:11:43 +02:00
Christian Flothmann
976b93a040 [Yaml] deprecate the !str tag
The tag specified in the YAML spec is actually !!str.
2017-06-25 08:10:51 +02:00
Fabien Potencier
e891d551b1 Merge branch '3.3' into 3.4
* 3.3:
  fixed tests
  swiftmailer bridge is gone
  respect the API in FirewallContext map
  [TwigBundle] add back exception check
  Dont call count on non countable object
  Fix undefined variable $filesystem
2017-06-24 09:45:46 -07:00
Fabien Potencier
7093fc1f24 Merge branch '3.2' into 3.3
* 3.2:
  fixed tests
  swiftmailer bridge is gone
  [TwigBundle] add back exception check
  Dont call count on non countable object
  Fix undefined variable $filesystem
2017-06-24 09:45:30 -07:00
Fabien Potencier
59094b406a Merge branch '2.8' into 3.2
* 2.8:
  fixed tests
  [TwigBundle] add back exception check
  Dont call count on non countable object
  Fix undefined variable $filesystem
2017-06-24 09:45:17 -07:00
Fabien Potencier
bf0063e3d3 fixed tests 2017-06-24 09:45:07 -07:00
Fabien Potencier
bddf9be8ce Merge branch '2.7' into 2.8
* 2.7:
  [TwigBundle] add back exception check
  Dont call count on non countable object
2017-06-24 09:44:49 -07:00
Fabien Potencier
7acc34537b bug #23279 Don't call count on non countable object (pierredup)
This PR was merged into the 2.7 branch.

Discussion
----------

Don't call count on non countable object

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

From PHP 7.2, calling `count` on a non-countable object will emit a warning (https://wiki.php.net/rfc/counting_non_countables).
Based on the current test suit, this is the only place where I found this warning

Commits
-------

635bccdf8f Dont call count on non countable object
2017-06-24 09:42:08 -07:00
Fabien Potencier
73e9348237 bug #23283 [TwigBundle] add back exception check (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[TwigBundle] add back exception check

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

#23268 introduced a regression in that the full exception page was not shown anymore in case a template for the given format (if not `html`) could not be found.

Commits
-------

46c38df0fd [TwigBundle] add back exception check
2017-06-24 09:41:09 -07:00
Ben Davies
2e435228d1 swiftmailer bridge is gone 2017-06-24 09:39:01 -07:00
Fabien Potencier
87601ba852 minor #23287 respect the API in FirewallContext map (xabbuh)
This PR was merged into the 3.3 branch.

Discussion
----------

respect the API in FirewallContext map

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

When being merged up, this will make the SecurityBundle tests on master
green again.

Commits
-------

ddf4368444 respect the API in FirewallContext map
2017-06-24 09:35:02 -07:00
Christian Flothmann
2b3d7f021d disable unusable fragment renderers 2017-06-24 15:56:34 +02:00
Christian Flothmann
ddf4368444 respect the API in FirewallContext map
When being merged up, this will make the SecurityBundle tests on master
green again.
2017-06-24 15:53:39 +02:00
Jose Gonzalez
7cda099663 [Stopwatch] Add a reset method 2017-06-24 13:12:40 +01:00
Christian Flothmann
265fc2a16a add missing version attribute 2017-06-24 13:17:41 +02:00
Christian Flothmann
411d9fa7a1 Merge branch '3.3' into 3.4
* 3.3: (64 commits)
  Show exception is checked twice in ExceptionController of twig
  allow SSI fragments configuration in XML files
  Display a better error message when the toolbar cannot be displayed
  render hidden _method field in form_rest()
  Add Doctrine Cache to dev dependencies to fix failing unit tests.
  return fallback locales whenever possible
  Fix Predis client cluster with pipeline
  [Dotenv] Test load() with multiple paths
  [Console] Fix catching exception type in QuestionHelper
  Improved the exception page when there is no message
  [WebProfilerBundle] Eliminate line wrap on count columnt (routing)
  [Validator] replace hardcoded service id
  [Routing] Fix XmlFileLoader exception message
  [DI] Dedup tags when using instanceof/autoconfigure
  [Translation] Fix FileLoader::loadResource() php doc
  Sessions: configurable "use_strict_mode" option for NativeSessionStorage
  [FrameworkBundle] [Command] Clean bundle directory, fixes #23177
  fixed CS
  [WebProfilerBundle] Fix the icon for the Cache panel
  [WebServerBundle] Fix router script path and check existence
  ...
2017-06-24 11:47:31 +02:00
Christian Flothmann
46c38df0fd [TwigBundle] add back exception check 2017-06-24 11:40:57 +02:00
Christian Flothmann
22723dafd4 Merge branch '3.2' into 3.3
* 3.2: (42 commits)
  Show exception is checked twice in ExceptionController of twig
  allow SSI fragments configuration in XML files
  Display a better error message when the toolbar cannot be displayed
  render hidden _method field in form_rest()
  Add Doctrine Cache to dev dependencies to fix failing unit tests.
  return fallback locales whenever possible
  [Console] Fix catching exception type in QuestionHelper
  [WebProfilerBundle] Eliminate line wrap on count columnt (routing)
  [Routing] Fix XmlFileLoader exception message
  [Translation] Fix FileLoader::loadResource() php doc
  Sessions: configurable "use_strict_mode" option for NativeSessionStorage
  [FrameworkBundle] [Command] Clean bundle directory, fixes #23177
  Reset redirectCount when throwing exception
  [TwigBundle] Remove template.xml services when templating is disabled
  add content-type header on exception response
  Embedding a response that combines expiration and validation, that should not defeat expiration on the combined response
  fixed bad merge
  Fix two edge cases in ResponseCacheStrategy
  [Routing] Expose request in route conditions, if needed and possible
  [Routing] Expose request in route conditions, if needed and possible
  ...
2017-06-24 11:29:48 +02:00
Fabien Potencier
9a9c3d1837 minor #23277 Fix undefined variable $filesystem (NVasse)
This PR was merged into the 2.8 branch.

Discussion
----------

Fix undefined variable $filesystem

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

<!--
- Bug fixes must be submitted against the lowest branch where they apply
  (lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the 3.4,
  legacy code removals go to the master branch.
- Please fill in this template according to the PR you're about to submit.
- Replace this comment by a description of what your PR is solving.
-->

Commits
-------

0724ebc5d2 Fix undefined variable $filesystem
2017-06-23 07:26:34 -07:00
Pierre du Plessis
635bccdf8f Dont call count on non countable object 2017-06-23 12:52:30 +02:00
Nicolas
0724ebc5d2 Fix undefined variable $filesystem 2017-06-23 11:32:10 +02:00
Christian Flothmann
80b114e66b Merge branch '2.8' into 3.2
* 2.8: (40 commits)
  Show exception is checked twice in ExceptionController of twig
  allow SSI fragments configuration in XML files
  Display a better error message when the toolbar cannot be displayed
  render hidden _method field in form_rest()
  return fallback locales whenever possible
  [Console] Fix catching exception type in QuestionHelper
  [WebProfilerBundle] Eliminate line wrap on count columnt (routing)
  [Routing] Fix XmlFileLoader exception message
  [Translation] Fix FileLoader::loadResource() php doc
  Sessions: configurable "use_strict_mode" option for NativeSessionStorage
  [FrameworkBundle] [Command] Clean bundle directory, fixes #23177
  Reset redirectCount when throwing exception
  [TwigBundle] Remove template.xml services when templating is disabled
  add content-type header on exception response
  Embedding a response that combines expiration and validation, that should not defeat expiration on the combined response
  Fix two edge cases in ResponseCacheStrategy
  [Routing] Expose request in route conditions, if needed and possible
  [Routing] Expose request in route conditions, if needed and possible
  [Translation][FrameworkBundle] Fix resource loading order inconsistency reported in #23034
  [Filesystem] added workaround in Filesystem::rename for PHP bug
  ...
2017-06-23 08:35:45 +02:00
Christian Flothmann
b4aa0271cb Merge branch '2.7' into 2.8
* 2.7:
  Show exception is checked twice in ExceptionController of twig
  allow SSI fragments configuration in XML files
  Display a better error message when the toolbar cannot be displayed
  render hidden _method field in form_rest()
  return fallback locales whenever possible
2017-06-23 07:57:41 +02:00
Fabien Potencier
9fc9cc4123 bug #23268 Show exception is checked twice in ExceptionController of twig (gmponos)
This PR was submitted for the 3.4 branch but it was merged into the 2.7 branch instead (closes #23268).

Discussion
----------

Show exception is checked twice in ExceptionController of twig

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| 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 |
| License       | MIT
| Doc PR        | N/A

I think that the $showException variable is checked twice. Check line 105 of the same file. Hope I did not miss anythings since the tests are passing.

Commits
-------

a433ceca41 Show exception is checked twice in ExceptionController of twig
2017-06-22 16:15:44 -07:00
George Mponos
a433ceca41 Show exception is checked twice in ExceptionController of twig 2017-06-22 16:15:38 -07:00
Fabien Potencier
f7de083cbd bug #23266 Display a better error message when the toolbar cannot be displayed (javiereguiluz)
This PR was merged into the 2.7 branch.

Discussion
----------

Display a better error message when the toolbar cannot be displayed

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

In action:

![profiler-error](https://user-images.githubusercontent.com/73419/27444352-5d0a1d60-5776-11e7-89c3-430cd6f38454.png)

Commits
-------

cc7275bccc Display a better error message when the toolbar cannot be displayed
2017-06-22 16:02:01 -07:00
Fabien Potencier
a66b967cae bug #23271 [FrameworkBundle] allow SSI fragments configuration in XML files (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[FrameworkBundle] allow SSI fragments configuration in XML files

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

Commits
-------

99931a994b allow SSI fragments configuration in XML files
2017-06-22 16:00:41 -07:00
Christian Flothmann
99931a994b allow SSI fragments configuration in XML files 2017-06-22 22:44:44 +02:00
Javier Eguiluz
cc7275bccc Display a better error message when the toolbar cannot be displayed 2017-06-22 18:11:34 +02:00
Fabien Potencier
2c438c5a25 feature #23026 [SecurityBundle] Add user impersonation info and exit action to the profiler (yceruto)
This PR was squashed before being merged into the 3.4 branch (closes #23026).

Discussion
----------

[SecurityBundle] Add user impersonation info and exit action to the profiler

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/23094
| License       | MIT

Toolbar item result:

![toolbar](https://cloud.githubusercontent.com/assets/2028198/26724555/1b60320a-4768-11e7-8433-da935f7068e9.png)

I'm no sure if more information should be displayed from source token, wdyt?

Security profile panel result:

![security_token_profile_panel](https://cloud.githubusercontent.com/assets/2028198/26705860/f7a64054-4706-11e7-9eef-6cd6b7365738.png)

Commits
-------

a3253f6db6 [SecurityBundle] Add user impersonation info and exit action to the profiler
2017-06-21 12:59:47 -07:00
Yonel Ceruto
a3253f6db6 [SecurityBundle] Add user impersonation info and exit action to the profiler 2017-06-21 12:59:45 -07:00
Fabien Potencier
7cc97b6e0b bug #23254 [Form][TwigBridge] render hidden _method field in form_rest() (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form][TwigBridge] render hidden _method field in form_rest()

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

Commits
-------

0ee3f57533 render hidden _method field in form_rest()
2017-06-21 12:28:21 -07:00
Christian Flothmann
0ee3f57533 render hidden _method field in form_rest() 2017-06-21 18:08:25 +02:00
Fabien Potencier
9a0d342226 bug #23250 [Translation] return fallback locales whenever possible (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[Translation] return fallback locales whenever possible

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

Commits
-------

3c21650d9e return fallback locales whenever possible
2017-06-21 07:18:43 -07:00
Fabien Potencier
7bb72b06fd bug #23237 [Cache] Fix Predis client cluster with pipeline (flolivaud)
This PR was merged into the 3.3 branch.

Discussion
----------

[Cache] Fix Predis client cluster with pipeline

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

a85d5b01f7 Fix Predis client cluster with pipeline
2017-06-21 07:12:54 -07:00
Fabien Potencier
b0bc9fea85 bug #23240 [Console] Fix catching exception type in QuestionHelper (voronkovich)
This PR was merged into the 2.8 branch.

Discussion
----------

[Console] Fix catching exception type in QuestionHelper

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

When generic exceptions were replaced by domain exceptions in dd17dc00ee one catch statement was missed. The existing code works fine because a `RuntimeException` extends a `\RuntimeException`.

Commits
-------

1c091eb703 [Console] Fix catching exception type in QuestionHelper
2017-06-21 07:10:56 -07:00
Fabien Potencier
5d3e776dd3 minor #23252 [TwigBundle] Add Doctrine Cache to dev dependencies to fix failing unit tests. (derrabus)
This PR was merged into the 3.2 branch.

Discussion
----------

[TwigBundle] Add Doctrine Cache to dev dependencies to fix failing unit tests.

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

Backporting #23166 to the `3.2` branch should make the `deps=high` builds pass again.

Commits
-------

2d8fdd9622 Add Doctrine Cache to dev dependencies to fix failing unit tests.
2017-06-21 06:59:45 -07:00
Fabien Potencier
16fbe3aac4 feature #22932 [HttpFoundation] Adds support for the immutable directive in the cache-control header (twoleds)
This PR was merged into the 3.4 branch.

Discussion
----------

[HttpFoundation] Adds support for the immutable directive in the cache-control header

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

Added support for the immutable directive in the cache-control header, tries to resolve #21425.

Commits
-------

33573c6eb1 Added support for the immutable directive in the cache-control header
2017-06-21 06:57:30 -07:00