Commit Graph

52259 Commits

Author SHA1 Message Date
Robin Chalas
ac2822f61f minor #39138 [Security] Removing Unused AnonymousPassport (weaverryan)
This PR was merged into the 5.2 branch.

Discussion
----------

[Security] Removing Unused AnonymousPassport

| Q             | A
| ------------- | ---
| Branch?       | 5.2
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | none
| License       | MIT
| Doc PR        | not needed

This is not used - it's leftover from the security component authenticator changes. I double-checked with @wouterj.

Cheers!

Commits
-------

79571e0e77 Removing AnonymousPassport
2020-11-22 15:59:58 +01:00
Ryan Weaver
79571e0e77 Removing AnonymousPassport
This is not used - is leftover from the security component
authenticator changes
2020-11-22 09:22:08 -05:00
Christian Flothmann
fe6a2dd64f prevent duplicated error message for file upload limits 2020-11-21 11:45:32 +01:00
Christian Flothmann
49eafee033 Merge branch '5.2' into 5.x
* 5.2:
  Bump Symfony version to 5.2.0
  Update VERSION for 5.2.0-RC2
  Update CHANGELOG for 5.2.0-RC2
  Display debug info
  [HttpFoundation] Typo on deprecation package name
  [DoctrineBridge] drop binary variants of UID types
  [HttpClient] don't fallback to HTTP/1.1 when HTTP/2 streams break
  Default to user provider, if available, in password upgrader
  fix lexing nested sequences/mappings
2020-11-21 10:41:20 +01:00
Christian Flothmann
bdadbf31a0 Merge branch '5.1' into 5.2
* 5.1:
  Display debug info
  [HttpClient] don't fallback to HTTP/1.1 when HTTP/2 streams break
  fix lexing nested sequences/mappings
2020-11-21 10:39:55 +01:00
Christian Flothmann
634d168d9c Merge branch '4.4' into 5.1
* 4.4:
  [HttpClient] don't fallback to HTTP/1.1 when HTTP/2 streams break
  fix lexing nested sequences/mappings
2020-11-21 10:37:14 +01:00
Fabien Potencier
af8bd4bd26 Bump Symfony version to 5.2.0 2020-11-21 09:49:39 +01:00
Fabien Potencier
cbce53759e
Merge pull request #39133 from fabpot/release-5.2.0-RC2
released v5.2.0-RC2
2020-11-21 09:46:11 +01:00
Fabien Potencier
192b826178 Update VERSION for 5.2.0-RC2 2020-11-21 09:45:53 +01:00
Fabien Potencier
81e11928ce Update CHANGELOG for 5.2.0-RC2 2020-11-21 09:45:38 +01:00
Fabien Potencier
ab9c4a7702 bug #39131 [Cache] Fix CI because of Couchbase version (jderusse)
This PR was merged into the 5.1 branch.

Discussion
----------

[Cache] Fix CI because of Couchbase version

| Q             | A
| ------------- | ---
| Branch?       | 5.1
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

It looks likes the version 3.0 of the couchbase extension does not exposes the `\CouchbaseCluster` class anymore.
I didn't find documentaiton about the BC break, but their documentation changes
version 2.6 => https://docs.couchbase.com/php-sdk/2.6/managing-connections.html
version 3.0 => https://docs.couchbase.com/php-sdk/current/howtos/managing-connections.html

It wasn't reported before, because `shivammathur/setup-php` added the extension 3days ago https://github.com/shivammathur/setup-php/pull/337

Sounds like the adapter were never tested, because the extension where missing and phpunit skipped the tests.

Commits
-------

fcbf0bf76e Display debug info
2020-11-21 06:48:12 +01:00
Alexander M. Turek
09a79d3f1f minor #39121 [HttpFoundation] Typo on deprecation package name (andersonamuller)
This PR was merged into the 5.2 branch.

Discussion
----------

[HttpFoundation] Typo on deprecation package name

| Q             | A
| ------------- | ---
| Branch?       | 5.2
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       |
| License       | MIT
| Doc PR        |

Commits
-------

4c6f4c7b9c [HttpFoundation] Typo on deprecation package name
2020-11-21 01:28:00 +01:00
Jérémy Derussé
fcbf0bf76e
Display debug info 2020-11-20 23:06:42 +01:00
Anderson Müller
4c6f4c7b9c
[HttpFoundation] Typo on deprecation package name 2020-11-20 18:25:36 +01:00
Alexander M. Turek
9ce2e86207 [HttpFoundation] Deprecate BinaryFileResponse::create(). 2020-11-20 16:47:02 +01:00
Robin Chalas
a273b71151 feature #39075 [Messenger]  Allow InMemoryTransport to serialize message (tyx)
This PR was merged into the 5.3-dev branch.

Discussion
----------

[Messenger]  Allow InMemoryTransport to serialize message

| Q             | A
| ------------- | ---
| Branch?       | 5.x
| Bug fix?      | no
| New feature?  | yes
| Deprecations? | no
| Tickets       | Fix #38893
| License       | MIT
| Doc PR        | wip

This introduce a query parameter in dsn to enable serialization as @Nyholm has suggested in #38893

`in-memory://?serialize=true`

Commits
-------

46a8007afc [Messenger] Allow InMemoryTransport to serialize message
2020-11-20 11:29:41 +01:00
Robin Chalas
04eec8bfc7 feature #38982 [Console][Yaml] Linter: add Github annotations format for errors (ogizanagi)
This PR was squashed before being merged into the 5.3-dev branch.

Discussion
----------

[Console][Yaml] Linter: add Github annotations format for errors

| Q             | A
| ------------- | ---
| Branch?       | 5.x <!-- see below -->
| Bug fix?      | no
| New feature?  | yes <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tickets       | N/A <!-- prefix each issue number with "Fix #", no need to create an issue if none exist, explain below instead -->
| License       | MIT
| Doc PR        | TODO

Github actions [can write errors and warning](https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-commands-for-github-actions#setting-an-error-message) directly in their output, which result into annotations into the Github checks. It can even provide a filename, line & col number, allowing to display the annnotations inside the PR diff directly, at the right place.

More advanced usage of annotations can be made using the [API](https://docs.github.com/en/free-pro-team@latest/rest/reference/checks#list-check-run-annotations), but regarding the linters provided in Symfony components, it seems the shortcut using output is a great way to enhance the integration with Github Actions.

This PR starts by proposing these changes in the yaml linter:
- add the `github` format, which is the same as the `txt` one, except for errors and warning, for which we'll adapt the output to the Github annotations format.
- remove the `txt` format as default, and autodetect if the script is running in a Github action context, then use `github` format. If it's not, we fallback to `txt` as before.

Once we agree on the details, we could perform the same for other linters (xliff, twig, ...)

Here is a PR using it: https://github.com/ogizanagi/symfony-lint-gha-demo/pull/2

and some screenshots:

| PR checks run | PR checks annotations | PR diff |
| -- | -- | -- |
| ![Capture d’écran 2020-11-04 à 09 37 07](https://user-images.githubusercontent.com/2211145/98089377-ed416600-1e82-11eb-8b10-40602b45efb1.png) | ![Capture d’écran 2020-11-04 à 09 37 28](https://user-images.githubusercontent.com/2211145/98089379-edd9fc80-1e82-11eb-8302-4e104abaeb2c.png) | ![Capture d’écran 2020-11-04 à 09 38 28](https://user-images.githubusercontent.com/2211145/98089381-edd9fc80-1e82-11eb-982a-9e4413ec30ba.png) |

~~(tests to add)~~

---

This was inspired by [PHPStan](d77bd87da9/src/Command/ErrorFormatter/GithubErrorFormatter.php) which is already auto-adapting the output according to the CI, using https://github.com/OndraM/ci-detector

Commits
-------

f0bbdc8d72 [Console][Yaml] Linter: add Github annotations format for errors
2020-11-20 09:48:18 +01:00
Maxime Steinhausser
f0bbdc8d72 [Console][Yaml] Linter: add Github annotations format for errors 2020-11-20 09:48:10 +01:00
Grégoire Paris
574a184b9a
Require doctrine/persistence 2
This allows us to remove autoload calls that are necessary for the
persistence 1 backwards-compatibility layer to work.
The require-dev constraints on doctrine/orm are bumped to ^2.7.3 because
lower versions are not compatible with doctrine/persistence 2.
2020-11-20 09:22:35 +01:00
Fabien Potencier
c13d5b5053 bug #39113 [DoctrineBridge] drop binary variants of UID types (nicolas-grekas)
This PR was merged into the 5.2 branch.

Discussion
----------

[DoctrineBridge] drop binary variants of UID types

| Q             | A
| ------------- | ---
| Branch?       | 5.2
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | #39112
| License       | MIT
| Doc PR        | -

#39112 made me realize that when the DB engine doesn't have a native UUID/GUID type, there's no benefit to representing ULIDs as UUIDs.

This PR proposes to use the native GUID type for both UUIDs and ULIDs only when the DB engine provides such a type, and to use `BINARY(16)` when the DB engine doesn't have a native GUID type.

This leaves us in a situation where, whether the DB engine supports GUID natively or not, UUID and ULID are always stored in the most compact format.

This makes the "binary" variants useless.

MySQL 8 has [functions](https://mysqlserverteam.com/mysql-8-0-uuid-support/) to deal with binary GUID, and so does [SQLite](https://sqlite.org/src/file/ext/misc/uuid.c).

Commits
-------

bdfc20520e [DoctrineBridge] drop binary variants of UID types
2020-11-19 10:31:30 +01:00
Fabien Potencier
b60bb6e2d6 bug #39115 [HttpClient] don't fallback to HTTP/1.1 when HTTP/2 streams break (nicolas-grekas)
This PR was merged into the 4.4 branch.

Discussion
----------

[HttpClient] don't fallback to HTTP/1.1 when HTTP/2 streams break

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix https://github.com/composer/composer/issues/9481
| License       | MIT
| Doc PR        | -

With this change, I don't reproduce the failures that I describe in https://github.com/composer/composer/issues/9481 when running the script in #38690

Apparently curl has an issue when both h1.1 and h2 connections are open to the same host.

Instead of switching to HTTP/1.1 when retrying requests that failed because of an HTTP/2 stream error, I propose to close the http/2 connection when issuing a retry.

With this change, running the mirroring script of packagist works like a charm.

No need to investigate your mirrors @Seldaek, this was definitely a data corruption issue.

Commits
-------

0c92bc5a83 [HttpClient] don't fallback to HTTP/1.1 when HTTP/2 streams break
2020-11-19 07:02:19 +01:00
Fabien Potencier
308231aafb bug #33763 [Yaml] fix lexing nested sequences/mappings (xabbuh)
This PR was merged into the 4.4 branch.

Discussion
----------

[Yaml] fix lexing nested sequences/mappings

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | #34805, #37788, #37876, #39011, #39013, #39064
| License       | MIT
| Doc PR        |

Commits
-------

4c15f80d84 fix lexing nested sequences/mappings
2020-11-19 06:58:37 +01:00
Nicolas Grekas
bdfc20520e [DoctrineBridge] drop binary variants of UID types 2020-11-19 01:44:06 +01:00
Nicolas Grekas
0c92bc5a83 [HttpClient] don't fallback to HTTP/1.1 when HTTP/2 streams break 2020-11-19 01:16:06 +01:00
Robin Chalas
de09329253 feature #39111 [Security] Update password upgrader listener to work with the new UserBadge (wouterj)
This PR was merged into the 5.2 branch.

Discussion
----------

[Security] Update password upgrader listener to work with the new UserBadge

| Q             | A
| ------------- | ---
| Branch?       | 5.2
| Bug fix?      | yes
| New feature?  | yes
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

While working on a new amazing `make:auth` maker, @jrushlow discovered that we forgot to update the `PasswordUpgradeBadge` with the 5.2 `UserBadge` changes (ref https://github.com/symfony/symfony/pull/37846).

This PR fixes it, by making the password upgrader optional and falling back to the user provider instead. Without these changes, each authenticator still needs to know the user repository/user provider in order to pass it to `PasswordUpgradeBadge`.

I'm sorry for catching this soo late in the release cycle. There is a BC break involved here, but it's (a) very unlikely to impact application code and (b) in an experimental class.

Commits
-------

e39e844606 Default to user provider, if available, in password upgrader
2020-11-18 22:42:13 +01:00
Wouter de Jong
e39e844606 Default to user provider, if available, in password upgrader 2020-11-18 22:00:38 +01:00
Alexander M. Turek
3c0cfbcb8c Merge branch '5.2' into 5.x
* 5.2:
  do not depend on the actual time to fix a transient test
  Run Redis Sentinel tests in GithubAction
  Minor : Removed typo (extra "the" term)
  Check if method inheritEnvironmentVariables exists
  [PhpUnitBridge] Fix test fixture file name
2020-11-18 11:00:07 +01:00
Alexander M. Turek
0302332238 Merge branch '5.1' into 5.2
* 5.1:
  do not depend on the actual time to fix a transient test
  Run Redis Sentinel tests in GithubAction
  Minor : Removed typo (extra "the" term)
  Check if method inheritEnvironmentVariables exists
  [PhpUnitBridge] Fix test fixture file name
2020-11-18 10:58:20 +01:00
Alexander M. Turek
3e90720bc1 Merge branch '4.4' into 5.1
* 4.4:
  do not depend on the actual time to fix a transient test
  Run Redis Sentinel tests in GithubAction
  Minor : Removed typo (extra "the" term)
  Check if method inheritEnvironmentVariables exists
  [PhpUnitBridge] Fix test fixture file name
2020-11-18 10:42:36 +01:00
Christian Flothmann
4c15f80d84 fix lexing nested sequences/mappings 2020-11-18 09:28:38 +01:00
Alexander M. Turek
1f0a27a732 Merge branch '3.4' into 4.4
* 3.4:
  Minor : Removed typo (extra "the" term)
  [PhpUnitBridge] Fix test fixture file name
2020-11-17 20:45:34 +01:00
Alexander M. Turek
218269e1e7 minor #39101 [HttpKernel] do not depend on the actual time to fix a transient test (xabbuh)
This PR was merged into the 4.4 branch.

Discussion
----------

[HttpKernel] do not depend on the actual time to fix a transient test

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       |
| License       | MIT
| Doc PR        |

Commits
-------

b7e5c7d67d do not depend on the actual time to fix a transient test
2020-11-17 19:38:25 +01:00
Christian Flothmann
b7e5c7d67d do not depend on the actual time to fix a transient test 2020-11-17 19:23:54 +01:00
Christian Flothmann
e7698e7434 ignore the pattern attribute for textareas 2020-11-17 17:25:11 +01:00
Fabien Potencier
3eec466502 bug #39083 [Dotenv] Check if method inheritEnvironmentVariables exists (Chi-teck)
This PR was merged into the 4.4 branch.

Discussion
----------

[Dotenv] Check if method inheritEnvironmentVariables exists

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #38201
| License       | MIT
| Doc PR        | -

Commits
-------

bd72a56505 Check if method inheritEnvironmentVariables exists
2020-11-17 06:58:42 +01:00
Fabien Potencier
728574d94f minor #39095 [Cache] Run Redis Sentinel tests in GithubAction (jderusse)
This PR was merged into the 4.4 branch.

Discussion
----------

[Cache] Run Redis Sentinel tests in GithubAction

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

Add support for Sentinel tests in GHA

Commits
-------

bd84394dc5 Run Redis Sentinel tests in GithubAction
2020-11-17 06:55:49 +01:00
Fabien Potencier
6564e0044d minor #39077 [PhpUnitBridge] Fix test fixture filename (fancyweb)
This PR was merged into the 3.4 branch.

Discussion
----------

[PhpUnitBridge] Fix test fixture filename

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | no
| License       | MIT
| Doc PR        | -

Fixes PHPUnit warning `Test case class not matching filename is deprecated`. I checked that the filename being different than the class name is not "required" for the test.

Commits
-------

c5a107e4cc [PhpUnitBridge] Fix test fixture file name
2020-11-17 06:50:42 +01:00
Karl Shea
d3b944046a [Ldap] Ldap Entry case-sensitive attribute key option 2020-11-16 19:46:08 +01:00
Alexander M. Turek
2fa929133b Merge branch '5.2' into 5.x
* 5.2:
  [Ldap] Fix undefined variable $con.
  Use GithubAction to run ldap tests
  Adds LDAP Adapter test in integration group
  Fix critical extension when reseting paged control
  Reinitialize globBrace after unserialization
2020-11-16 19:25:18 +01:00
Alexander M. Turek
fb52afaf53 Merge branch '5.1' into 5.2
* 5.1:
  [Ldap] Fix undefined variable $con.
  Use GithubAction to run ldap tests
  Adds LDAP Adapter test in integration group
  Fix critical extension when reseting paged control
  Reinitialize globBrace after unserialization
2020-11-16 19:02:40 +01:00
Fabien Potencier
e3cce5102a minor #39093 [Finder] Minor : Removed typo (extra "the" term) in hasResults() method documentation (Levure)
This PR was merged into the 3.4 branch.

Discussion
----------

[Finder] Minor : Removed typo (extra "the" term) in hasResults() method documentation

| Q             | A
| ------------- | ---
| Branch?       | 3.4 (as recommended by https://symfony.com/doc/current/contributing/code/pull_requests.html#choose-the-right-branch)
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | no
| License       | MIT
| Doc PR        | no

Commits
-------

160cc6144c Minor : Removed typo (extra "the" term)
2020-11-16 18:38:26 +01:00
Alexander M. Turek
e05dc00d99 Merge branch '4.4' into 5.1
* 4.4:
  [Ldap] Fix undefined variable $con.
2020-11-16 18:33:12 +01:00
Alexander M. Turek
d6f27fa670 bug #39094 [Ldap] Fix undefined variable $con (derrabus)
This PR was merged into the 4.4 branch.

Discussion
----------

[Ldap] Fix undefined variable $con

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | https://github.com/symfony/symfony/pull/39030#issuecomment-728156901
| License       | MIT
| Doc PR        | N/A

This PR extracts the connection resource into a variable. This will fix an undefined variable error on 5.1.

Commits
-------

15da31686a [Ldap] Fix undefined variable $con.
2020-11-16 18:30:45 +01:00
Jérémy Derussé
bd84394dc5
Run Redis Sentinel tests in GithubAction 2020-11-16 18:15:10 +01:00
Alexander M. Turek
15da31686a [Ldap] Fix undefined variable $con. 2020-11-16 18:05:55 +01:00
Bruno Baguette
160cc6144c
Minor : Removed typo (extra "the" term) 2020-11-16 18:02:08 +01:00
Alexander M. Turek
3372b3ef96 Merge branch '4.4' into 5.1
* 4.4:
  Use GithubAction to run ldap tests
  Adds LDAP Adapter test in integration group
  Fix critical extension when reseting paged control
  Reinitialize globBrace after unserialization
2020-11-16 16:58:32 +01:00
Alexander M. Turek
55707fbcba minor #39030 [LDAP] Add ldap tests to github CI (lucasaba, jderusse)
This PR was merged into the 4.4 branch.

Discussion
----------

[LDAP] Add ldap tests to github CI

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #39028
| License       | MIT
| Doc PR        |

Adds LDAP test on github actions pipeline and corrects sum bugs in the LDAP Component test

It also adds a bug resolution from @Nek- made in #38875

Commits
-------

ea78f728b1 Use GithubAction to run ldap tests
af9562b12c Adds LDAP Adapter test in integration group
2020-11-16 16:51:33 +01:00
Jérémy Derussé
ea78f728b1
Use GithubAction to run ldap tests 2020-11-16 16:15:08 +01:00
Alexander M. Turek
cf70d3a180 bug #39091 [Config] Recheck glob brace support after GlobResource was serialized (wouterj)
This PR was merged into the 4.4 branch.

Discussion
----------

[Config] Recheck glob brace support after GlobResource was serialized

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

cc @bastnic

This bug was reported on Symfony Slack: `$this->globBrace` is set to `null` after unserialization from the `.meta` file.

Instead of serializing this property, I decided to reinitialize the property after unserialization. I think that's a safer option (e.g. it works when the cache is build on a different server with different globBrace support than the one running the application).

Commits
-------

d9534779cf Reinitialize globBrace after unserialization
2020-11-16 15:38:21 +01:00