Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion DependencyInjection/Compiler/AddProcessorsPass.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
*/
class AddProcessorsPass implements CompilerPassInterface
{
public function process(ContainerBuilder $container)
public function process(ContainerBuilder $container): void
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a breaking change. We should think about releasing a new major.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or use that trait trick you created :)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a breaking change. We should think about releasing a new major.

Sure. If so, we could also think about removing support of sf < 6.4.

Or use that trait trick you created :)

What trait trick? I'm curious 🙂

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

even the trait trick would be a BC break (but a conditional one, which is even worse to communicate)

However, given the time since the last major version, I think we could do one.

If so, we could also think about removing support of sf < 6.4.

this does not actually require a major version. We can do it in a minor version if we ensure we update the composer requirements properly (as composer will install compatible packages)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or use that trait trick you created :)

What trait trick? I'm curious 🙂

🙈 https://github.com/doctrine/dbal/blob/3.10.x/src/Tools/Console/Command/CommandCompatibility.php 🙈

I would prefer to go with a new major here in the case of our bundle.

{
if (!$container->hasDefinition('monolog.logger')) {
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
*/
class AddSwiftMailerTransportPass implements CompilerPassInterface
{
public function process(ContainerBuilder $container)
public function process(ContainerBuilder $container): void
{
$handlers = $container->getParameter('monolog.swift_mailer.handlers');

Expand Down
2 changes: 1 addition & 1 deletion DependencyInjection/Compiler/DebugHandlerPass.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public function __construct(LoggerChannelPass $channelPass)
$this->channelPass = $channelPass;
}

public function process(ContainerBuilder $container)
public function process(ContainerBuilder $container): void
{
if (!$container->hasDefinition('profiler')) {
return;
Expand Down
2 changes: 1 addition & 1 deletion DependencyInjection/Compiler/FixEmptyLoggerPass.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function __construct(LoggerChannelPass $channelPass)
$this->channelPass = $channelPass;
}

public function process(ContainerBuilder $container)
public function process(ContainerBuilder $container): void
{
$container->register('monolog.handler.null_internal', 'Monolog\Handler\NullHandler');
foreach ($this->channelPass->getChannels() as $channel) {
Expand Down
2 changes: 1 addition & 1 deletion DependencyInjection/Compiler/LoggerChannelPass.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class LoggerChannelPass implements CompilerPassInterface
{
protected $channels = ['app'];

public function process(ContainerBuilder $container)
public function process(ContainerBuilder $container): void
{
if (!$container->hasDefinition('monolog.logger')) {
return;
Expand Down
8 changes: 3 additions & 5 deletions DependencyInjection/MonologExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ class MonologExtension extends Extension
* @param array $configs An array of configuration settings
* @param ContainerBuilder $container A ContainerBuilder instance
*/
public function load(array $configs, ContainerBuilder $container)
public function load(array $configs, ContainerBuilder $container): void
{
$configuration = $this->getConfiguration($configs, $container);
$config = $this->processConfiguration($configuration, $configs);
Expand Down Expand Up @@ -144,15 +144,13 @@ public function load(array $configs, ContainerBuilder $container)

/**
* Returns the base path for the XSD files.
*
* @return string The XSD base path
*/
public function getXsdValidationBasePath()
public function getXsdValidationBasePath(): string
{
return __DIR__.'/../Resources/config/schema';
}

public function getNamespace()
public function getNamespace(): string
{
return 'http://symfony.com/schema/dic/monolog';
}
Expand Down
2 changes: 1 addition & 1 deletion MonologBundle.php
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<?php

/*
Expand Down Expand Up @@ -31,7 +31,7 @@
/**
* @return void
*/
public function build(ContainerBuilder $container)
public function build(ContainerBuilder $container): void
{
parent::build($container);

Expand Down
14 changes: 7 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,16 @@
],
"require": {
"php": ">=7.2.5",
"symfony/monolog-bridge": "^5.4 || ^6.0 || ^7.0",
"symfony/dependency-injection": "^5.4 || ^6.0 || ^7.0",
"symfony/config": "^5.4 || ^6.0 || ^7.0",
"symfony/http-kernel": "^5.4 || ^6.0 || ^7.0",
"symfony/monolog-bridge": "^5.4 || ^6.0 || ^7.0 || ^8.0",
"symfony/dependency-injection": "^5.4 || ^6.0 || ^7.0 || ^8.0",
"symfony/config": "^5.4 || ^6.0 || ^7.0 || ^8.0",
"symfony/http-kernel": "^5.4 || ^6.0 || ^7.0 || ^8.0",
"monolog/monolog": "^1.25.1 || ^2.0 || ^3.0"
},
"require-dev": {
"symfony/yaml": "^5.4 || ^6.0 || ^7.0",
"symfony/console": "^5.4 || ^6.0 || ^7.0",
"symfony/phpunit-bridge": "^7.1"
"symfony/yaml": "^5.4 || ^6.0 || ^7.0 || ^8.0",
"symfony/console": "^5.4 || ^6.0 || ^7.0 || ^8.0",
"symfony/phpunit-bridge": "^7.1 || ^8.0"
},
"autoload": {
"psr-4": { "Symfony\\Bundle\\MonologBundle\\": "" },
Expand Down
Loading