Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[FlashBag] Add peekMultiple method #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 599 commits into
base: 6.3
Choose a base branch
Loading
from
Open

[FlashBag] Add peekMultiple method #1

wants to merge 599 commits into from

Conversation

alexmerlin
Copy link
Owner

Q A
Branch? 6.3
Bug fix? no
New feature? no
Deprecations? no
Tickets Fix symfony#49659
License MIT
Doc PR -

This PR adds the peekMultiple method to FlashBag and AutoExpireFlashBag, as requested in symfony#49659.

derrabus and others added 30 commits July 25, 2023 15:03
This PR was merged into the 2.3-dev branch.

Discussion
----------

Prepare release 2.3.0

Commits
-------

96acbfd Prepare release 2.3.0
…olas-grekas)

This PR was merged into the 6.4 branch.

Discussion
----------

Add types to private and internal properties

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

Commits
-------

6353f5e Add types to private and internal properties
…e initialization on SymfonyRuntime (l-vo)

This PR was merged into the 6.4 branch.

Discussion
----------

[Runtime] Fix property must not be accessed before initialization on SymfonyRuntime

| Q             | A
| ------------- | ---
| Branch?       | 6.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       |
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Introduced by symfony#51068, see symfony#51068 (comment)

Commits
-------

dd3c406 Fix property must not be accessed before initialization on SymfonyRuntime::$input
…arsed body (nicolas-grekas)

This PR was merged into the 2.3 branch.

Discussion
----------

Don't rely on Request::getPayload() to populate the parsed body

That's just not needed and creates issues like symfony#121

+ fixes a bug with invalid jsons.

Commits
-------

ef03b6d Don't rely on Request::getPayload() to populate the parsed body
This PR was merged into the 6.4 branch.

Discussion
----------

[Mailer] fix deprecation versions

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

Commits
-------

6000311 fix deprecation versions
This PR was merged into the 6.4 branch.

Discussion
----------

[Mailer] update the Brevo SMTP host

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

see https://developers.brevo.com/docs/changes-in-smtp-relay-address

Commits
-------

5662858 update the Brevo SMTP host
…alls (fancyweb)

This PR was merged into the 6.4 branch.

Discussion
----------

Remove \ReflectionProperty::setAccessible(true) calls

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

Commits
-------

9e78833 Remove \ReflectionProperty::setAccessible(true) calls
…e set_error_handler/set_exception_handler calls (lyrixx)

This PR was merged into the 6.4 branch.

Discussion
----------

Use more "First class callable syntax" + Normalize set_error_handler/set_exception_handler calls

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

Commits
-------

be1bbbc Use more "First class callable syntax" + Normalize set_error_handler/set_exception_handler calls
* 6.3:
  [Mime] Fix lowest versions of deps
  [VarDumper] Fix calling scope detection inside magic accessors
  [Validator] add missing German translations
  [Serializer] Fix denormalizing abstract part headers in MimeMessageNormalizer
  [Form] Remove an obsolete phpdoc comment
  [Webhook] Allow slash in webhook type
  [FrameworkBundle][Workflow] Throw exception is workflow.xxx.transitions is not an array
* 6.3:
  Remove noise from .github/expected-missing-return-types.diff
…s + etc. (nicolas-grekas)

This PR was merged into the 6.4 branch.

Discussion
----------

More short closures + isset instead of null checks + etc.

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

Some of the isset() checks are needed to make symfony#51069 green on high-deps job.

Commits
-------

3df6471 More short closures + isset instead of null checks + etc.
This PR was merged into the 6.4 branch.

Discussion
----------

Ensure all properties have a type

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

Before symfony#51069

Commits
-------

25a8615 Ensure all properties have a type
…butes (derrabus)

This PR was merged into the 6.4 branch.

Discussion
----------

[Serializer] Fix tests for extended Context attributes

| Q             | A
| ------------- | ---
| Branch?       | 6.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Follows symfony#50983
| License       | MIT
| Doc PR        | not needed

In symfony#50983, I broke one test scenario where we test that extending the `Context` class works. This PR corrects that mistake.

Commits
-------

2a6e93e [Serializer] Fix tests for extended Context attributes
* 6.3:
  [Cache] Fix generating proxies when ext-redis v6 is installed
  [Serializer] Fix deserializing nested arrays of objects with mixed keys
…0de5ff08ee1ba6850a0ee472e'

git-subtree-dir: src/Symfony/Bridge/PsrHttpMessage
git-subtree-mainline: 510e51f
git-subtree-split: 581ca60
nicolas-grekas and others added 27 commits August 8, 2023 12:13
…ements by a simple Null Coalescing Operator ,KernelTestCase::createKernel (IssamRaouf)

This PR was submitted for the 6.3 branch but it was merged into the 6.4 branch instead.

Discussion
----------

[FrameworkBundle] [Test] Replace Conditional statements by a simple Null Coalescing Operator ,KernelTestCase::createKernel

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

Replace Conditional statements  by a simple Null Coalescing Operator

Commits
-------

dd85a16 Update KernelTestCase.php
… nested option (flohw)

This PR was squashed before being merged into the 6.4 branch.

Discussion
----------

[OptionsResolver] Improve invalid type message on nested option

| Q             | A
| ------------- | ---
| Branch?       | 6.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | not required I think

OptionsResolver exception message is very explicit on which option has an invalid value with the full path of the option on lazy option. But the message only showed the latest option name when the type is not valid. This PR fixes it and display the full option path of the lazy option's invalid type.

Commits
-------

16a6f38 [OptionsResolver] Improve invalid type message on nested option
* 6.3:
  [DoctrineBridge] Silence ORM deprecation
  add missing default-doctrine-dbal-provider cache pool attribute to XSD
* 6.3:
  [Mailer] update Brevo SMTP host
  change default doctrine DBAL provider to XML attribute
…s_session` config option (alamirault)

This PR was squashed before being merged into the 6.4 branch.

Discussion
----------

[SecurityBundle] Deprecate the `require_previous_session` config option

| Q             | A
| ------------- | ---
| Branch?       | 6.4
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | yes <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tickets       | Fix symfony#51318  <!-- prefix each issue number with "Fix #", no need to create an issue if none exists, explain below instead -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

This PR deprecate the `require_previous_session` config option

Remove is done in symfony#51333 on 7.0

Commits
-------

f92b0fc [SecurityBundle] Deprecate the `require_previous_session` config option
…s-grekas)

This PR was merged into the 6.4 branch.

Discussion
----------

Remove unneeded calls to setPublic(false)

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

It's already the default since a few years.

Commits
-------

ca8d441 Remove unneeded calls to setPublic(false)
…ng workflow in profiler (lyrixx)

This PR was merged into the 6.4 branch.

Discussion
----------

[Workflow] Use TRANSITION_TYPE_WORKFLOW for rendering workflow in profiler

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

---

This one is a bit special.

Usually a state machine render like this:

![image](https://github.com/symfony/symfony/assets/408368/50f45620-aa88-4fc8-97c2-1049c08b2ee7)

As you can see, **transitions** (ex: `start_process`) are not real nodes. They are arrows.

And it's not possible to attach events on arrows, only on nodes.

That's why I add this hybrid mode, where state machine are rendered like a workflow. It means transitions are renderered as node:

![image](https://github.com/symfony/symfony/assets/408368/80f6731a-2d02-4eab-be2d-77ab67495006)

Now, we can attach event on transition nodes.

Commits
-------

0cdf2b8 [Workflow] Use TRANSITION_TYPE_WORKFLOW for rendering workflow in profiler
This PR was squashed before being merged into the 6.4 branch.

Discussion
----------

[Notifier] Add GoIP bridge

| Q             | A
| ------------- | ---
| Branch?       | 6.4
| Bug fix?      | no
| New feature?  | yes
| Deprecations? | no
| Tickets       |
| License       | MIT
| Doc PR        | symfony/symfony-docs#18742
| Recipes       | symfony/recipes#1233

GoIP is a GSM Gateway/SIM-Hub that provides the ability to send SMS messages over the network. I think it would be useful to add an integration for it with the Symfony Notifier

Commits
-------

066d0f8 [Notifier] Add GoIP bridge
This PR was squashed before being merged into the 6.4 branch.

Discussion
----------

[Notifier][Webhook] Add Vonage support

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

Add support for `RemoteEvent` & `Webhook` to Vonage Notifier Bridge

Event statuses and payloads come from Vonage [documentation](https://developer.vonage.com/en/api/messages-olympus#inbound-message-req-body).

Commits
-------

490adc1 [Notifier][Webhook] Add Vonage support
…abbuh)

This PR was merged into the 6.4 branch.

Discussion
----------

[Notifier] rename GoIP notifier bridge to GoIp

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

Let's be consistent in naming our bridges.

Commits
-------

c2feb5e rename GoIP notifier bridge to GopIp
* 6.3:
  [AssetMapper] Fixing bug where a circular exception could be thrown while making error message
  Dump Valid constaints on debug command symfony#46544
  [DependencyInjection] fix dump xml with array/object/enum default value
  [HttpFoundation] Add a slightly more verbose comment about a warning on UploadedFile
  [Messenger] BatchHandlerTrait - fix phpdoc typo
  [SecurityBundle] Remove unused test files
  Allow passing an `inline_service` to a `service_locator`
  [Security] Fix error with lock_factory in login_throttling
  fix(console): fix section output when multiples section with max height
  Remove me from CODEOWNERS
  Fix invalid method call + improve exception message
  Always return bool from messenger amqp conncetion nack
  [FrameworkBundle] Fix xsd handle-all-throwables
  [Console] Fix linewraps in OutputFormatter
This PR was merged into the 6.4 branch.

Discussion
----------

[Notifier] fix directory casing

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

Commits
-------

0942d6e fix directory casing
…(xabbuh)

This PR was merged into the 6.4 branch.

Discussion
----------

[Validator]  replace annotations with attributes

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

Commits
-------

cf3879c replace annotations with attributes
alexmerlin pushed a commit that referenced this pull request Nov 25, 2024
This PR was merged into the 5.4 branch.

Discussion
----------

[Process] Fixed inconsistent test

| Q             | A
| ------------- | ---
| Branch?       | 5.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Issues        | N/A
| License       | MIT

Sometimes the process no longer appears to be running when the signal is sent which causes a LogicException to be thrown. This doesn't appear to be consistent and I can reproduce it randomly on my local machine. To avoid having tests fail at random I decided that it's better to send the signal only if the process is still marked as running.

```bash
amne@wnbpowerbox:~/work/projects/symfony$ php7.4 src/Symfony/Component/Process/Tests/ErrorProcessInitiator.php
The process "'php' '-r' 'echo '\''ready'\''; trigger_error('\''error'\'', E_USER_ERROR);'" exceeded the timeout of 0.5 seconds.
amne@wnbpowerbox:~/work/projects/symfony$ php7.4 src/Symfony/Component/Process/Tests/ErrorProcessInitiator.php
The process "'php' '-r' 'echo '\''ready'\''; trigger_error('\''error'\'', E_USER_ERROR);'" exceeded the timeout of 0.5 seconds.
amne@wnbpowerbox:~/work/projects/symfony$ php7.4 src/Symfony/Component/Process/Tests/ErrorProcessInitiator.php
The process "'php' '-r' 'echo '\''ready'\''; trigger_error('\''error'\'', E_USER_ERROR);'" exceeded the timeout of 0.5 seconds.
amne@wnbpowerbox:~/work/projects/symfony$ php7.4 src/Symfony/Component/Process/Tests/ErrorProcessInitiator.php
The process "'php' '-r' 'echo '\''ready'\''; trigger_error('\''error'\'', E_USER_ERROR);'" exceeded the timeout of 0.5 seconds.
amne@wnbpowerbox:~/work/projects/symfony$ php7.4 src/Symfony/Component/Process/Tests/ErrorProcessInitiator.php
PHP Fatal error:  Uncaught Symfony\Component\Process\Exception\LogicException: Cannot send signal on a non running process. in /home/amne/work/projects/symfony/src/Symfony/Component/Process/Process.php:1502
Stack trace:
#0 /home/amne/work/projects/symfony/src/Symfony/Component/Process/Process.php(516): Symfony\Component\Process\Process->doSignal()
#1 /home/amne/work/projects/symfony/src/Symfony/Component/Process/Tests/ErrorProcessInitiator.php(28): Symfony\Component\Process\Process->signal()
symfony#2 {main}
  thrown in /home/amne/work/projects/symfony/src/Symfony/Component/Process/Process.php on line 1502
```

Commits
-------

00ee4ca [Process] Fixed inconsistent test
alexmerlin pushed a commit that referenced this pull request Nov 25, 2024
…read from socket (xdanik)

This PR was merged into the 5.4 branch.

Discussion
----------

[Mailer] Throw `TransportException` when unable to read from socket

| Q             | A
| ------------- | ---
| Branch?       | 5.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? |no
| Issues        | None
| License       | MIT

We are seeing error `fgets(): SSL: Connection reset by peer` multiple times a day from connection to Office 365 SMTP server (smtp.office365.com:587).
It's certainly related to some kind of timeout as we are sending emails from long running queue dispatcher and error shows up only occasionally and never with the first message. We are not seeing this issue with any other SMTP server, but we have not tested much past smtp.mandrillapp.com and local MailHog.

We have tried adjusting the `$pingThreshold` and `$restartThreshold` options, but without much success (well `$restartThreshold = 1` resolves the issue, but it also forces the transport to close connection after each message).

Stack trace:
```
#0 /var/www/vendor/symfony/mailer/Transport/Smtp/Stream/AbstractStream.php(77): fgets(Resource(stream))
#1 /var/www/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php(315): Symfony\Component\Mailer\Transport\Smtp\Stream\AbstractStream->readLine()
symfony#2 /var/www/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php(181): Symfony\Component\Mailer\Transport\Smtp\SmtpTransport->getFullResponse()
symfony#3 /var/www/vendor/symfony/mailer/Transport/Smtp/SmtpTransport.php(140): Symfony\Component\Mailer\Transport\Smtp\SmtpTransport->executeCommand("RSET
", Array(1))
symfony#4 /var/www/vendor/symfony/mailer/Mailer.php(45): Symfony\Component\Mailer\Transport\Smtp\SmtpTransport->send(Object(Symfony\Component\Mime\Email), Null)
symfony#5 (our queue dispatcher): Symfony\Component\Mailer\Mailer->send(Object(Symfony\Component\Mime\Email))
```

App is running on PHP 8.0.28 on Debian Linux x64, Mailer v5.4.22.

I would gladly written some tests for this, but I don't know how to simulate calls to low-level stream functions like fgets.

Commits
-------

44d5b57 [Mailer] Throw TransportException when unable to read from socket
alexmerlin pushed a commit that referenced this pull request Nov 25, 2024
…ling error with no ExpectedTypes (Jeroeny)

This PR was merged into the 6.3 branch.

Discussion
----------

[HttpKernel] Fix `RequestPayloadValueResolver` handling error with no ExpectedTypes

| Q             | A
| ------------- | ---
| Branch?       | 6.3
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| License       | MIT

The `NotNormalizableValueException` errors in `PartialDenormalizationException->getErrors()` have a `->getExpectedTypes()` method that returns `array|null`.  The `RequestPayloadValueResolver` assumes this is always an array.

When the returned value is `null`, an Exception is thrown with `implode(): Argument #1 ($pieces) must be of type array, string given`.

Also the exception message in case of an empty array was: `This value should be of type .`.

#SymfonyHackday

Commits
-------

0af85fe Fix RequestPayloadValueResolver handling error with no ExpectedTypes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

FlashBag peekMultiple() method
Morty Proxy This is a proxified and sanitized view of the page, visit original site.