A Week of Symfony #834 (19-25 December 2022)


This week, the upcoming Symfony 6.3 version added lots of new features, such as support for nesting autowiring-related attributes, allow to use HttpStatus attribute to set status code and headers for HTTP exceptions, introduce a feature to strip emojis in text contents and new methods for Clock component. In addition, Symfony published the Symfony Book updated for Symfony 6.2.

Symfony development highlights

This week, 40 pull requests were merged (33 in code and 7 in docs) and 37 issues were closed (26 in code and 11 in docs). Excluding merges, 30 authors made 6,550 additions and 353 deletions. See details for code and docs.

5.4 changelog:

  • ff94390: Add compatibility with doctrine/annotations 2
  • 4e26f68: [Workflow] allow spaces in place names so the PUML dump doesn't break
  • f3b892d: [Validator] fix IBAN format for Tunisia and Mauritania
  • 2aedd16: [VarExporter] fix exporting classes with __unserialize() but not __serialize()
  • 4362f6e: use static methods inside data providers
  • 4eb8013: [Cache] RedisTrait::createConnection does not pass auth value from redis sentinel cluster DSN
  • e7ec8a6: [CssSelector] fix escape patterns

6.2 changelog:

  • 4d5d6ba: [SecurityBundle] prevent RuntimeException on profiler
  • d43ba3b: [VarExporter] generate proxies for static abstract methods
  • 8d7a37a: [PropertyAccess] fix nullsafe chain like x?.y
  • ca27741: [Translation] fix undefined variable messages in ConstraintVisitor

6.3 changelog:

  • 5ae4dc4: [WebProfilerBundle] add a title and img role to SVG of the web debug toolbar
  • 52b5bb7: [Yaml] add flag to dump numeric key as string
  • be1dfc7: [DependencyInjection] add support for nesting autowiring-related attributes into #[Autowire(...)]
  • 65e65ac: [HttpKernel] allow using #[HttpStatus] for setting status code and headers for HTTP exceptions
  • ecf5f63: [Security] make login redirection logic available to programmatic login
  • fcfca3e: [Messenger] do not return fallback senders when other senders were already found
  • a826eb3: [FrameworkBundle, Messenger] add support for namespace wildcard in Messenger routing
  • 5bfb260: [Clock] add Clock class and now() function
  • 4586963: remove calls to AnnotationRegistry::registerLoader()
  • 85590ec: [Security] add generics to PasswordUpgraderInterface
  • dfcb811: [HttpKernel] resolve DateTime value using the Clock
  • ad892c1: [Intl] add a special locale to strip emojis easily with EmojiTransliterator
  • 8cc74f1: [Notifier] GoogleChat CardsV1 is deprecated we must use cardsV2 instead
  • ff6913e: [DependencyInjection] deprecate integer keys in service_locator config
  • 50a1641: [FrameworkBundle] deprecate framework:exceptions XML tag
  • 24fdf38: [Validator] add getConstraint() method to ConstraintViolationInterface
  • 9df40aa: [SecurityBundle] rename firewalls.logout.csrf_token_generator to firewalls.logout.csrf_token_manager
  • e9870a4: [DependencyInjection] target Attribute must fail if the target does not exist

Newest issues and pull requests

Symfony CLI

Symfony CLI is a must-have tool when developing
Symfony applications on your local machine. It includes the
Symfony Local Server,
the best way to run local Symfony applications. This week Symfony CLI released
its new 5.4.20
version with the following changes:

  • Expose the CLI version and binary name when running console, php and composer wrappers (@tucksaun)
  • Change book requirements to match for the Symfony 6.2 version (@fabpot)
  • Add support for PHP version selection based on config.platform.php in composer.json (@tucksaun)
  • Add local:proxy:url command (@Kocal)
  • Fix only force Git main branch name for new project when --cloud is used (@tucksaun)
  • Fix Local Sever should respect the daemon option from .symfony.local.yaml (@tucksaun)

SymfonyCasts Updates

SymfonyCasts is the official way to learn Symfony.
Select a track for a guided path through 100+ video tutorial courses about
Symfony, PHP and JavaScript.

These were some of the most relevant SymfonyCasts updates
of the week:

They talked about us

Call to Action

Sponsor the Symfony project.