fabpot
Repos
72
Followers
12861

The Symfony PHP framework

28148
8786

Twig, the flexible, fast, and secure template language for PHP

7734
1140

Split a repository to read-only standalone repositories

1463
65

The Symfony CLI tool

414
77

Events

closed issue
[Cache] Fix DBAL deprecations and stop using NUL chars in tags prefix

| Q | A | ------------ | --- | Feature PR | symfony/symfony#49847 | PR author(s) | @nicolas-grekas | Merged in | 6.3

We created this issue to not forget to document this new feature. We would really appreciate if you can help us with this task. If you are not sure how to do it, please ask us and we will help you.

To fix this issue, please create a PR against the 6.3 branch in the symfony-docs repository.

Thank you! :smiley:

Created at 12 hours ago
issue comment
[flex] Symfony 3.x and 4.x removed from Flex endpoint. "extra.symfony.require" has no effect.

I've just fixed it.

Created at 13 hours ago
closed issue
[flex] Symfony 3.x and 4.x removed from Flex endpoint. "extra.symfony.require" has no effect.

Hello,

we were trying to update our Composer dependencies of our Symfony 4.4 project this morning and realized, that various Symfony components got updated to their Symfony 5.x version.

After some digging, we found out, that the typical Restricting packages listed in "symfony/symfony" to "4.4.*" message wasn't displayed any longer. And after digging into the Flex plugin's code, we found the link to the main flex json: https://raw.githubusercontent.com/symfony/recipes/flex/main/index.json

This lead us to this repo, where we found out, that yesterday, the index.json was updated. See: https://github.com/symfony/recipes/commit/4058a63c6a0b75a617f8d1ec0a1d89ff9a49281f

All Symfony 3.x and 4.x splits where removed, which makes composer fallback to the highest version possible.

This can easily be reproduced by calling composer create-project symfony/skeleton:"4.4.*" my_project_directory: The created project uses a variety of Symfony 5.x components, although its composer.json restricts them to 4.4.*.

This makes composer up unusable without manually restricting every Symfony component to 4.4.*.

Can someone help? How is this file generated?

Created at 13 hours ago

Update versions.json

Created at 13 hours ago
create repository
fabpot create repository
Created at 13 hours ago

Update versions.json

Created at 13 hours ago
pull request closed
[Validator] Revert "feature #49789 New `PasswordStrength` constraint (Spomky)"

This reverts commit c37540613922ec64cc8ff0e0a4ad21bd6b4ddb74, reversing changes made to 497e9666de46420299e2732cf2e97451b2792bf0.

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

The dev dependency added in #49789 looks problematic: https://github.com/bjeavons/zxcvbn-php has no commit in 2 years, ignored vulnerability reports + unmerged php compatibility fixes. Worse, the JS project it's based on didn't make any change in 6 years, has ignored security reports as well and seems to be officially abandoned (https://github.com/dropbox/zxcvbn/issues/290, https://github.com/dropbox/zxcvbn/issues/295).

I propose to revert this change for now, then revisit the topic as soon as possible. Also some core members argued that this feature could be better handled on the frontend i.e. rewritten as a UX component or a cookbook example. Either way, if we want to do re-add this, we would need to fork and update the abandoned package. And if it's frontend, we need to find a maintained alternative.

Created at 13 hours ago
pull request closed
[Cache] Fix storing binary keys when using pgsql

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

Created at 13 hours ago

[Cache] Fix storing binary keys when using pgsql

bug #49848 [Cache] Fix storing binary keys when using pgsql (nicolas-grekas)

This PR was merged into the 5.4 branch.

Discussion

[Cache] Fix storing binary keys when using pgsql

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

Commits

be88fd00f8 [Cache] Fix storing binary keys when using pgsql

Created at 13 hours ago
issue comment
[Cache] Fix storing binary keys when using pgsql

Thank you @nicolas-grekas.

Created at 13 hours ago
pull request closed
[Notifier] Add SimpleTextin bridge

| Q | A | ------------- | --- | Branch? | 6.3 | Bug fix? | no | New feature? | yes | Deprecations? | no | Tickets | | License | MIT[ | Doc PR | https://github.com/symfony/symfony-docs/pull/17510 | Recipe | https://github.com/symfony/recipes/pull/1160

Created at 13 hours ago

[Notifier] Add SimpleTextin bridge

feature #48495 [Notifier] Add SimpleTextin bridge (gnito-org)

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

Discussion

[Notifier] Add SimpleTextin bridge

| Q | A | ------------- | --- | Branch? | 6.3 | Bug fix? | no | New feature? | yes | Deprecations? | no | Tickets | | License | MIT[ | Doc PR | https://github.com/symfony/symfony-docs/pull/17510 | Recipe | https://github.com/symfony/recipes/pull/1160

Commits

f2d9af6f94 [Notifier] Add SimpleTextin bridge

Created at 13 hours ago
issue comment
[Notifier] Add SimpleTextin bridge

Thank you @gnito-org.

Created at 13 hours ago

[HttpFoundation] ParameterBag::getEnum()

[Clock] Fix unitialized variable

bug #48870 [Clock] Fix unitialized variable (fabpot)

This PR was merged into the 6.3 branch.

Discussion

[Clock] Fix unitialized variable

| Q | A | ------------- | --- | Branch? | 6.3 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | n/a

Commits

2df462301c [Clock] Fix unitialized variable

remove double required annotation + attribute

feature #48685 [DependencyInjection] Exclude referencing service (self) in TaggedIteratorArgument (chalasr)

This PR was merged into the 6.3 branch.

Discussion

[DependencyInjection] Exclude referencing service (self) in TaggedIteratorArgument

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

Suggested by @OskarStark in https://twitter.com/OskarStark/status/1594641457226436608?s=20&t=Wbqw_Mu2tMYQ0iouaG8yig. This PR avoids the need to explicitly indicate to exclude the referencing service when using #[TaggedIterator] and variants.

Before:

final class DelegatingErrorTracker implements ErrorTracker
{
    public function __construct(
        #TaggedIterator(ErrorTracker::class, exclude: self::class)]
        private iterable $trackers
    ) {}
}

After:

final class DelegatingErrorTracker implements ErrorTracker
{
    public function __construct(
        #TaggedIterator(ErrorTracker::class]
        private iterable $trackers
    ) {}
}

I went with no deprecation as I think the breakage potential is close to zero, but happy to reconsider.

Commits

1cadd46e7f [DependencyInjection] Auto exclude referencing service in TaggedIteratorArgument

feature #48820 [HttpFoundation] ParameterBag::getEnum() (nikophil)

This PR was merged into the 6.3 branch.

Discussion

[HttpFoundation] ParameterBag::getEnum()

| Q | A | ------------- | --- | Branch? | 6.3 | Bug fix? | no | New feature? | yes | Deprecations? | no | License | MIT | Doc PR | todo if the PR gets accepted

Adds availability to get an enum directly from a parameter bag:

$bag->getEnum('key', Foo::class)

Commits

e4ba7b7552 [HttpFoundation] ParameterBag::getEnum()

[Validator] fix: Case-insensitive extensions in File-Constraint

bug #48866 [Validator] fix: Case-insensitive extensions in File-Constraint (spackmat)

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

Discussion

[Validator] fix: Case-insensitive extensions in File-Constraint

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

This PR fixes the problem described in #48859 by normalizing the checked file-extension in the File Constraint to lowercase, when the extensions check is used. Previously a file with a .TXT extension was considered invalid, when the .txt extension was allowed by the Constraint. The test case was also updated.

Commits

3a2b2354c7 [Validator] fix: Case-insensitive extensions in File-Constraint

[HttpKernel] Allow using #[WithLogLevel] for setting custom log level for exceptions

feature #48747 [HttpKernel] Allow using #[WithLogLevel] for setting custom log level for exceptions (angelov)

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

Discussion

[HttpKernel] Allow using #[WithLogLevel] for setting custom log level for exceptions

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

With these changes, we're extending the functionality for setting a custom log level for a given exception by introducing a new WithLogLevel attribute.

Example:

#[WithLogLevel(\Psr\Log\LogLevel::CRITICAL)]
class AccountBalanceIsNegative extends \Exception
{
}

This will have a lower priority compared to the log level set using the option in the configuration files. (Meaning that if we have both an attribute declared on an exception class, and another level set for the same class in the configuration, the one from the configuration will be used.)

Commits

0a2563d561 [HttpKernel] Allow using #[WithLogLevel] for setting custom log level for exceptions

[HttpKernel] Rename HttpStatus atribute to WithHttpStatus

bug #48846 [Translation] Fix for resolving Constraint Validator FQCN defined as %foo.bar.class% parameters (gassan)

This PR was merged into the 6.2 branch.

Discussion

[Translation] Fix for resolving Constraint Validator FQCN defined as %foo.bar.class% parameters

For example Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntityValidator is defined as %doctrine.orm.validator.unique.class% and must be properly resolved.

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

Commits

c965b032f6 [Translation] Fix for resolving Constraint Validator FQCN defined as %foo.bar.class% parameters

[FrameworkBundle] Add extra attribute for HttpClient Configuration

feature #48797 [FrameworkBundle] Add extra attribute for HttpClient Configuration (voodooism)

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

Discussion

[FrameworkBundle] Add extra attribute for HttpClient Configuration

| Q | A | ------------- | --- | Branch? | 6.3 | Bug fix? | no | New feature? | yes | Deprecations? | no | License | MIT | Doc PR | coming soon...

I want to configure HttpClient once in configure file and forget about the configuration when doing a request or injection. In my particular case, I want to pass certificates to the client as raw values using special curlopts. Here https://github.com/symfony/symfony/pull/48775 proposed the best way to do it - using extra attribute in configuration.

It's going to look like so

return static function (FrameworkConfig $frameworkConfig): void {
    $httpClient = $frameworkConfig->httpClient();
    $httpClient->defaultOptions([
        'extra' => ['curl' => ['foo' => 'bar']]
    ]);

    $httpClient->scopedClient('some_client')
        ->baseUri('https://some.uri')
        ->header('Accept', 'application/json')
        ->extra(['curl' => ['foo' => 'bar']]);
}

Commits

6c898944d6 [FrameworkBundle] Add extra attribute for HttpClient Configuration

bug #48830 [Translation] fix PhpAstExtractor also extracts messages if t() contains both unnamed and named arguments (gassan)

This PR was merged into the 6.2 branch.

Discussion

[Translation] fix PhpAstExtractor also extracts messages if t() contains both unnamed and named arguments

The case for $translator->trans('some message', domain: 'foo') was not covered by PhpAstExtractor.

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

Commits

96a020bb57 [Translation] fix PhpAstExtractor also extracts messages from t()/trans() that contains both unnamed and named arguments

[Intl] Get emoji-test.txt from unicode.org

feature #48876 [HttpKernel] Rename HttpStatus atribute to WithHttpStatus (fabpot)

This PR was merged into the 6.3 branch.

Discussion

[HttpKernel] Rename HttpStatus atribute to WithHttpStatus

| Q | A | ------------- | --- | Branch? | 6.3 | Bug fix? | yes-ish | New feature? | no | Deprecations? | no | Tickets | Refs #48352 and #48747

As discussed in the 2 referenced PRs for better naming consistency.

Commits

fece76621b [HttpKernel] Rename HttpStatus atribute to WithHttpStatus

Fix detecting mapping with one line annotations

[Console] fix clear of section with question

Fix ParameterBagTest message with PHP 8.2

Created at 13 hours ago
pull request closed
[Cache] Fix DBAL deprecations and stop using NUL chars in tags prefix

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

The change of the tag prefix is motivated by #49713.

The other changes are to accommodate for deprecations in DBAL.

Note that DoctrineDbalAdapter::getServerVersion() keep calling the deprecated getWrappedConnection() method because although the code says one should exist, there is no alternative way to access the server version. Drivers are all missing a getServerVersion() method (/cc @derrabus FYI)

Created at 13 hours ago

[Cache] Fix DBAL deprecations and stop using NUL chars in tags prefix

feature #49847 [Cache] Fix DBAL deprecations and stop using NUL chars in tags prefix (nicolas-grekas)

This PR was merged into the 6.3 branch.

Discussion

[Cache] Fix DBAL deprecations and stop using NUL chars in tags prefix

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

The change of the tag prefix is motivated by #49713.

The other changes are to accommodate for deprecations in DBAL.

Note that DoctrineDbalAdapter::getServerVersion() keep calling the deprecated getWrappedConnection() method because although the code says one should exist, there is no alternative way to access the server version. Drivers are all missing a getServerVersion() method (/cc @derrabus FYI)

Commits

f4398a1452 [Cache] Fix DBAL deprecations and stop using NUL chars in tags prefix

Created at 13 hours ago
opened issue
[Cache] Fix DBAL deprecations and stop using NUL chars in tags prefix

| Q | A | ------------ | --- | Feature PR | symfony/symfony#49847 | PR author(s) | @nicolas-grekas | Merged in | 6.3

We created this issue to not forget to document this new feature. We would really appreciate if you can help us with this task. If you are not sure how to do it, please ask us and we will help you.

To fix this issue, please create a PR against the 6.3 branch in the symfony-docs repository.

Thank you! :smiley:

Created at 13 hours ago
issue comment
[Cache] Fix DBAL deprecations and stop using NUL chars in tags prefix

Thank you @nicolas-grekas.

Created at 13 hours ago
issue comment
[ErrorHandler] Improve error messages in CLI

@javiereguiluz I'd love to be able to merge this one in 6.3 :)

Created at 13 hours ago