Commit Graph

34734 Commits

Author SHA1 Message Date
Fabien Potencier
6c81b6df3c bug #26590 Make sure form errors is valid HTML (Nyholm)
This PR was merged into the 3.4 branch.

Discussion
----------

Make sure form errors is valid HTML

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

Using `<div>` and `<ul>` in a `<label>` is not valid HTML. This PR uses `<span>`s instead and some Bootstrap 4 classes to make it look just like before.

Commits
-------

5dcaaadb5e Make sure form errors is valid HTML
2018-03-18 20:24:00 +01:00
Fabien Potencier
2c838f94b3 feature #26408 Readd 'form_label_errors' block to disable errors on form labels (birkof)
This PR was merged into the 3.4 branch.

Discussion
----------

Readd 'form_label_errors' block to disable errors on form labels

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| 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 files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| License       | MIT

Re-added **form_label_errors** block on bootstrap 4 form themes.
You can disable errors shown on form labels by simply extend bootstrap4 layout and empty **form_label_errors** block. See below:
```
{% use "bootstrap_4_layout.html.twig" %}

{# Disable errors shown on form labels #}
{% block form_label_errors %}{% endblock form_label_errors %}
```
Block previously removed [here](b375957c8b (diff-62cb2a10f5a37db0e87e3bd81609b17dR186)) by @nicolas-grekas.
cc @Nyholm

Commits
-------

5b4354f46c Readd 'form_label_errors' block to disable errors on form labels
2018-03-18 20:12:33 +01:00
Fabien Potencier
c59bbc554f bug #26591 [TwigBridge] Make sure we always render errors. Eventhough labels are disabled (Nyholm)
This PR was merged into the 3.4 branch.

Discussion
----------

[TwigBridge] Make sure we always render errors. Eventhough labels are disabled

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

If one use form type with `'label'=>false` then no errors where visible. This PR make sure we always print errors.

Commits
-------

d8f3de91d5 Make sure we always render errors. Eventhough labels are disabled
2018-03-18 20:01:56 +01:00
Nyholm
d8f3de91d5 Make sure we always render errors. Eventhough labels are disabled 2018-03-18 15:50:20 +01:00
Nyholm
5dcaaadb5e Make sure form errors is valid HTML 2018-03-18 15:29:46 +01:00
Nicolas Grekas
866a1429b7 minor #26551 [Serializer] Remove const override (ogizanagi)
This PR was merged into the 3.4 branch.

Discussion
----------

[Serializer] Remove const override

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no <!-- 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 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        | N/A

This public const was moved to parent class in https://github.com/symfony/symfony/pull/24816

Commits
-------

25312c4 [Serializer] Remove const override
2018-03-16 10:13:00 +01:00
Nicolas Grekas
60303eb721 minor #26546 Extra line to bootstrap 3 horizontal layout (okorneliuk)
This PR was submitted for the master branch but it was merged into the 3.4 branch instead (closes #26546).

Discussion
----------

Extra line to bootstrap 3 horizontal layout

This file ends with no newline character. It won't render properly on a terminal, and it's considered a bad practice.

| Q             | A
| ------------- | ---
| Branch?       | master for features / 2.7 up to 4.0 for bug fixes <!-- see below -->
| Bug fix?      | no
| 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#... <!-- required for new features -->

Commits
-------

83c4f4c Extra line to bootstrap 3 horizontal layout
2018-03-16 09:39:14 +01:00
okorneliuk
83c4f4c7f0 Extra line to bootstrap 3 horizontal layout
This file ends with no newline character. It won't render properly on a terminal, and it's considered a bad practice.
2018-03-16 09:39:13 +01:00
Maxime Steinhausser
25312c4671 [Serializer] Remove const override 2018-03-15 20:08:29 +01:00
Fabien Potencier
985ef53b51 minor #26508 Update Client.php (jrean)
This PR was submitted for the master branch but it was squashed and merged into the 3.4 branch instead (closes #26508).

Discussion
----------

Update Client.php

Docblock.

Commits
-------

5d7b13110b Update Client.php
2018-03-13 09:46:25 -05:00
Jean Ragouin
5d7b13110b Update Client.php 2018-03-13 09:46:24 -05:00
Fabien Potencier
822483b9bf bug #26482 [PhpUnitBridge] Ability to use different composer.json file (amcastror)
This PR was submitted for the master branch but it was squashed and merged into the 3.4 branch instead (closes #26482).

Discussion
----------

[PhpUnitBridge] Ability to use different composer.json file

Hi, I have a project where I use a different composer.json via environment variable. Look [here](https://getcomposer.org/doc/03-cli.md#composer). Because of this, $root gets set to "/" and everything fails.

Hope this helps.

| Q             | A
| ------------- | ---
| Branch?       | master for features / 2.7 up to 4.0 for bug fixes <!-- see below -->
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | I'll add if this is useful.
| Fixed tickets |
| License       | MIT
| Doc PR        | symfony/symfony-docs

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - 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 master branch.
-->

Commits
-------

77e643d0ba [PhpUnitBridge] Ability to use different composer.json file
2018-03-13 07:34:33 -05:00
amcastror
77e643d0ba [PhpUnitBridge] Ability to use different composer.json file 2018-03-13 07:34:32 -05:00
Fabien Potencier
8f4a0b61c5 bug #26443 [Fix][3.4][HttpFoundation] Fix the updating of timestamp in the MemcachedSessionHandler (Alessandro Loffredo)
This PR was merged into the 3.4 branch.

Discussion
----------

[Fix][3.4][HttpFoundation] Fix the updating of timestamp in the MemcachedSessionHandler

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

Conditions: Symfony 3.4, PHP7 and sessions handled over memcache.

Apparently `memcached::touch()` returns `false` on a subsequent call with the same parameters. Since `updateTimestamp` is used in `AbstractSessionHandler::write()`

```
public function write($sessionId, $data)
    {
        if (\PHP_VERSION_ID < 70000 && $this->prefetchData) {
            $readData = $this->prefetchData;
            $this->prefetchData = null;

            if ($readData === $data) {
                return $this->updateTimestamp($sessionId, $data);
            }
        }
...
```

the result is that `write()` will return `false` on **any subsequent request within the same second** causing the following error:

```
HP Fatal error:  Uncaught Symfony\Component\Debug\Exception\ContextErrorException: Warning: session_write_close(): Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/var/lib/php/sessions) in Unknown:0
Stack trace:
#0 [internal function]: Symfony\Component\Debug\ErrorHandler->handleError(2, 'session_write_c...', 'Unknown', 0, NULL)
#1 [internal function]: session_write_close()
#2 {main}
  thrown in Unknown on line 0
```

Can be reproduced on `symfony/skeleton:3.4` adding the following code to `public/index.php` and performing two consecutive requests:
```
$session = $kernel->getContainer()->get('session');
$session->set("foo", "bar");
```

Commits
-------

d007469877 fix the updating of timestamp in the MemcachedSessionHandler
2018-03-13 07:32:20 -05:00
Fabien Potencier
957588a12e minor #26496 [DomCrawler] FormField: remove a useless return statement (dunglas)
This PR was submitted for the master branch but it was merged into the 3.4 branch instead (closes #26496).

Discussion
----------

[DomCrawler] FormField: remove a useless return statement

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no <!-- 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 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        | n/a

Commits
-------

6ca8b4beeb [DomCrawler] FormField: remove an useless return statement
2018-03-13 07:30:05 -05:00
Kévin Dunglas
6ca8b4beeb [DomCrawler] FormField: remove an useless return statement 2018-03-13 07:30:05 -05:00
Fabien Potencier
ebfcab3759 minor #26421 [Config] Add characters to the regex (DavidPrevot)
This PR was merged into the 3.4 branch.

Discussion
----------

[Config] Add characters to the regex

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

Commits
-------

dff88d44be [Config] Add characters to the regex
2018-03-13 07:27:50 -05:00
Fabien Potencier
f77db05895 bug #26400 [Config] ReflectionClassResource check abstract class (andrey1s)
This PR was merged into the 3.4 branch.

Discussion
----------

[Config] ReflectionClassResource check abstract class

generate Signature
update hash methods `ServiceSubscriberInterface::getSubscribedServices` and `EventSubscriberInterface::getSubscribedEvents` if the class is not abstract

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #26459, #26501
| License       | MIT

Commits
-------

e85151483c [Config] ReflectionClassResource check abstract ServiceSubscriberInterface and EventSubscriberInterface
2018-03-13 07:22:24 -05:00
andrey1s
e85151483c [Config] ReflectionClassResource check abstract ServiceSubscriberInterface and EventSubscriberInterface 2018-03-12 22:05:25 +01:00
Fabien Potencier
2655496eba bug #26041 Display the Welcome Page when there is no homepage defined (javiereguiluz)
This PR was squashed before being merged into the 3.4 branch (closes #26041).

Discussion
----------

Display the Welcome Page when there is no homepage defined

| 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-docs/issues/9178
| License       | MIT
| Doc PR        | -

In 3.4 we added a trick to display the Welcome Page when the user browses `/` and there are no routes defined. However, when using the `website-skeleton` (which is what most newcomers use ... and they are the ones that mostly need the "Welcome Page") the premise about *"no routes are defined"* is never true and the Welcome Page is never shown (see https://github.com/symfony/symfony-docs/issues/9178 for one of the multiple error reports we've received).

So, I propose to make this change to always define the "Welcome Page" as the fallback:

* If no routes are defined for `/`, the Welcome Page is displayed.
* If there is a route defined for `/`, this code will never be executed because it's the last condition of the routing matcher.

Commits
-------

5b0d9340d7 Display the Welcome Page when there is no homepage defined
2018-03-11 13:19:37 -05:00
Javier Eguiluz
5b0d9340d7 Display the Welcome Page when there is no homepage defined 2018-03-11 13:19:35 -05:00
Alessandro Loffredo
d007469877 fix the updating of timestamp in the MemcachedSessionHandler 2018-03-07 14:52:09 +01:00
Robin Chalas
07cccd53df minor #26424 [SecurityBundle] Make extra character non mandatory in regex (DavidPrevot)
This PR was merged into the 3.4 branch.

Discussion
----------

[SecurityBundle] Make extra character non mandatory in regex

The extra character was introduced in 5f9471e, and breaks the testsuite
in native php 7.2.

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

Commits
-------

44b4fc8 [SecurityBundle] Make extra character non mandatory in regex
2018-03-06 10:27:07 +01:00
David Prévot
44b4fc8db5 [SecurityBundle] Make extra character non mandatory in regex
The extra character was introduced in 5f9471e, and breaks the testsuite
in native php 7.2.
2018-03-05 22:53:32 -10:00
David Prévot
dff88d44be [Config] Add characters to the regex
This allow paths containing ~ and + (as used in version number in Debian
for example) to be used while running the testsuite.
2018-03-05 16:10:46 -10:00
Fabien Potencier
d6fd5798ea bumped Symfony version to 3.4.7 2018-03-05 14:26:20 -08:00
Fabien Potencier
874d4d6597
Merge pull request #26416 from fabpot/release-3.4.6
released v3.4.6
2018-03-05 12:02:01 -08:00
Fabien Potencier
932c275e65 updated VERSION for 3.4.6 2018-03-05 11:41:07 -08:00
Fabien Potencier
b010f4ffee updated CHANGELOG for 3.4.6 2018-03-05 11:40:57 -08:00
Fabien Potencier
ab07cddf04 Merge branch '2.8' into 3.4
* 2.8:
  Improve the documentation of `Finder::exclude()`
2018-03-05 10:28:11 -08:00
Fabien Potencier
a03ae7c194 Merge branch '2.7' into 2.8
* 2.7:
  Improve the documentation of `Finder::exclude()`
2018-03-05 10:27:59 -08:00
Fabien Potencier
fc1b1dd0ed bug #26393 [DI] Skip resource tracking if disabled (chalasr)
This PR was merged into the 3.4 branch.

Discussion
----------

 [DI] Skip resource tracking if disabled

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

Commits
-------

0b748fac95 [DI] Skip resource tracking if disabled
2018-03-05 08:14:30 -08:00
Daniel STANCU
5b4354f46c Readd 'form_label_errors' block to disable errors on form labels 2018-03-05 15:16:24 +02:00
Fabien Potencier
3379310dd6 minor #26396 Improve the documentation of Finder::exclude() (mnapoli)
This PR was merged into the 2.7 branch.

Discussion
----------

Improve the documentation of `Finder::exclude()`

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | no
| New feature?  | no <!-- 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 files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets |
| License       | MIT
| Doc PR        |

Tried to do this and this didn't work:

```php
$iterator->in($sourcePath)
    ->exclude($sourcePath.'/foo');
```

I read on http://symfony.com/doc/current/components/finder.html that excluded directories need to be relative:

![capture d ecran 2018-03-04 a 16 10 31](https://user-images.githubusercontent.com/720328/36947055-28e47eda-1fc7-11e8-9475-399a3d853169.png)

Commits
-------

cc3084ed65 Improve the documentation of `Finder::exclude()`
2018-03-04 08:34:45 -08:00
Matthieu Napoli
cc3084ed65
Improve the documentation of Finder::exclude() 2018-03-04 16:13:29 +01:00
Robin Chalas
0b748fac95 [DI] Skip resource tracking if disabled 2018-03-04 04:54:53 +01:00
Nicolas Grekas
cfb243e61a Merge branch '2.8' into 3.4
* 2.8:
  [WebProfilerBundle] fix wrong variable for profiler counting ajax requests
2018-03-02 16:26:15 +01:00
Nicolas Grekas
710a189e83 Merge branch '2.7' into 2.8
* 2.7:
  [WebProfilerBundle] fix wrong variable for profiler counting ajax requests
2018-03-02 16:25:13 +01:00
Nicolas Grekas
79e8545f86 minor #26373 [WebProfilerBundle] fix wrong variable for profiler counting ajax requests (Marin Nicolae)
This PR was squashed before being merged into the 2.7 branch (closes #26373).

Discussion
----------

[WebProfilerBundle] fix wrong variable for profiler counting ajax requests

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

Symfony WebProfiler base js change variable tbodies to tbody for counting Ajax Requests.

Commits
-------

0fb83af [WebProfilerBundle] fix wrong variable for profiler counting ajax requests
2018-03-02 16:24:45 +01:00
Marin Nicolae
0fb83af015 [WebProfilerBundle] fix wrong variable for profiler counting ajax requests 2018-03-02 16:24:40 +01:00
Nicolas Grekas
6ac7b50021 bug #26355 [DI] Fix missing "id" normalization when dumping the container (nicolas-grekas)
This PR was merged into the 3.4 branch.

Discussion
----------

[DI] Fix missing "id" normalization when dumping the container

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

Commits
-------

4a5e43e [DI] Fix missing "id" normalization when dumping the container
2018-03-02 15:13:11 +01:00
Nicolas Grekas
4a5e43eae8 [DI] Fix missing "id" normalization when dumping the container 2018-03-02 14:51:21 +01:00
Nicolas Grekas
8f1a6b5d65 minor #26276 [Doc] Add entry for container.dumper.inline_class_loader param at UPGRADE-3.4.md and UPGRADE-4.0.md (phansys)
This PR was merged into the 3.4 branch.

Discussion
----------

[Doc] Add entry for `container.dumper.inline_class_loader` param at `UPGRADE-3.4.md` and `UPGRADE-4.0.md`

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

Commits
-------

d6e2b81 Add entry for `container.dumper.inline_class_loader` param at `UPGRADE-3.4.md` and `UPGRADE-4.0.md`
2018-03-02 13:17:15 +01:00
Nicolas Grekas
fe4d055bd7 Merge branch '2.8' into 3.4
* 2.8:
  [WebProfilerBundle] Fix Debug toolbar breaks app
  bumped Symfony version to 2.8.36
  updated VERSION for 2.8.35
  updated CHANGELOG for 2.8.35
  bumped Symfony version to 2.7.43
  updated VERSION for 2.7.42
  update CONTRIBUTORS for 2.7.42
  updated CHANGELOG for 2.7.42
2018-03-02 09:27:00 +01:00
Nicolas Grekas
aa8254ce2f Merge branch '2.7' into 2.8
* 2.7:
  [WebProfilerBundle] Fix Debug toolbar breaks app
  bumped Symfony version to 2.7.43
  updated VERSION for 2.7.42
  update CONTRIBUTORS for 2.7.42
  updated CHANGELOG for 2.7.42
2018-03-02 09:25:37 +01:00
Nicolas Grekas
0c5f8391f9 bug #26368 [WebProfilerBundle] Fix Debug toolbar breaks app (xkobal)
This PR was squashed before being merged into the 2.7 branch (closes #26368).

Discussion
----------

[WebProfilerBundle] Fix Debug toolbar breaks app

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26364
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Wrong method is used to count `tbody.rows`

Commits
-------

52f187e [WebProfilerBundle] Fix Debug toolbar breaks app
2018-03-02 09:20:34 +01:00
Xavier HAUSHERR
52f187e86a [WebProfilerBundle] Fix Debug toolbar breaks app 2018-03-02 09:20:32 +01:00
Nicolas Grekas
9980004cb4 bug #26369 Use fill instead of style for svg colors (rpkamp)
This PR was merged into the 3.4 branch.

Discussion
----------

Use fill instead of style for svg colors

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

Using style does not work when a Content Security Policy is in place,
resulting in non-styles (black) images instead of grey.

Symfony 2.7 and 2.8 don't have these images so there is nothing to fix there.

Commits
-------

e296778 Use fill instead of style for svg colors
2018-03-02 09:19:22 +01:00
Remon van de Kamp
e29677858f
Use fill instead of style for svg colors
Using style does not work when a Content Security Policy is in place,
resulting in non-styles (black) images instead of grey.
2018-03-02 09:07:37 +01:00
Javier Spagnoletti
d6e2b8188c Add entry for container.dumper.inline_class_loader param at UPGRADE-3.4.md and UPGRADE-4.0.md 2018-03-01 21:43:47 -03:00