diff --git a/Kernel/System/MigrateFromOTRS/CloneDB/Driver/Base.pm b/Kernel/System/MigrateFromOTRS/CloneDB/Driver/Base.pm index 6ef2a25902..f78e442601 100644 --- a/Kernel/System/MigrateFromOTRS/CloneDB/Driver/Base.pm +++ b/Kernel/System/MigrateFromOTRS/CloneDB/Driver/Base.pm @@ -342,8 +342,9 @@ sub DataTransfer { # Open for writing as the file usually does not exist yet. # This approach assumes that the the webserver processes are running on a single machine. my $LockFile = join '/', $ConfigObject->Get('Home'), 'var/tmp/migrate_from_otrs.lock'; - # TODO: why still warnings from Perl::Critic ?? + ## no critic qw(OTOBO::ProhibitLowPrecedenceOps OTOBO::ProhibitOpen InputOutput::RequireBriefOpen) + open my $LockFh, '>', $LockFile or do { $MigrationBaseObject->MigrationLog( String => "Could not open lockfile $LockFile; $!", diff --git a/Kernel/System/MigrateFromOTRS/OTOBOCopyFilesFromOTRS.pm b/Kernel/System/MigrateFromOTRS/OTOBOCopyFilesFromOTRS.pm index 1eadd4639b..b096b18c61 100644 --- a/Kernel/System/MigrateFromOTRS/OTOBOCopyFilesFromOTRS.pm +++ b/Kernel/System/MigrateFromOTRS/OTOBOCopyFilesFromOTRS.pm @@ -345,7 +345,6 @@ sub ReConfigure { # Write new config file, the file handle is autoclosed as it is lexical to the block { - # TODO: find out why the warning is still reported open my $Out, '>:encoding(utf-8)', $ConfigFile or return "Can't open $ConfigFile: $!"; ## no critic qw(OTOBO::ProhibitLowPrecedenceOps) print $Out $Config; diff --git a/Kernel/System/MigrateFromOTRS/OTOBOOTRSConnectionCheck.pm b/Kernel/System/MigrateFromOTRS/OTOBOOTRSConnectionCheck.pm index 9b427e7af3..78f4d44f10 100644 --- a/Kernel/System/MigrateFromOTRS/OTOBOOTRSConnectionCheck.pm +++ b/Kernel/System/MigrateFromOTRS/OTOBOOTRSConnectionCheck.pm @@ -244,7 +244,6 @@ sub _CheckConfigpmAndWriteCache { my %CacheOptions; { - ## TODO: why does Perl::Critic still complain about OTOBO::ProhibitOpen ?? open( my $In, '<', $ConfigFile ) ## no critic qw(OTOBO::ProhibitOpen) or return "Can't open $ConfigFile: $!"; ## no critic qw(OTOBO::ProhibitLowPrecedenceOps) diff --git a/Kernel/System/UnitTest/RegisterDriver.pm b/Kernel/System/UnitTest/RegisterDriver.pm index 0e9d09d8a7..57962e6b79 100644 --- a/Kernel/System/UnitTest/RegisterDriver.pm +++ b/Kernel/System/UnitTest/RegisterDriver.pm @@ -41,9 +41,8 @@ use utf8; # OTOBO modules use Kernel::System::ObjectManager; -# TODO: why still warnings from Perl::Critic ??, find better location for the no critic -## no critic qw(OTOBO::RequireCamelCase) -sub import { + +sub import { ## no critic qw(OTOBO::RequireCamelCase) # RegisterDriver is meant for test scripts, # meaning that each sript has it's own process. diff --git a/Kernel/System/UnitTest/Selenium.pm b/Kernel/System/UnitTest/Selenium.pm index 5f3cd1edd3..1c9371f92b 100644 --- a/Kernel/System/UnitTest/Selenium.pm +++ b/Kernel/System/UnitTest/Selenium.pm @@ -259,8 +259,8 @@ Therefore override that subroutine. =cut -# TODO: where to put 'no critic qw(OTOBO::RequireCamelCase)' -sub button_up { +sub button_up { ## no critic qw(OTOBO::RequireCamelCase) + my ($Self) = @_; if ( $Self->{is_wd3} diff --git a/Kernel/System/Web/Exception.pm b/Kernel/System/Web/Exception.pm index c694a33bba..4e7a874b19 100644 --- a/Kernel/System/Web/Exception.pm +++ b/Kernel/System/Web/Exception.pm @@ -78,9 +78,7 @@ make use of a caught exception object =cut -# TODO: why still warnings from Perl::Critic ?? -## no critic qw(OTOBO::RequireCamelCase) -sub as_psgi { +sub as_psgi { ## no critic qw(OTOBO::RequireCamelCase) my $Self = shift; # The thrower created the error message diff --git a/scripts/backup.pl b/scripts/backup.pl index b079123e9e..a42447ccea 100755 --- a/scripts/backup.pl +++ b/scripts/backup.pl @@ -194,7 +194,6 @@ my $Directory = join '/', $BackupDir, $SystemDTObject->Format( Format => '%Y-%m-%d_%H-%M-%S' ); -# TODO: why still warnings from Perl::Critic ?? mkdir $Directory or die "ERROR: Can't create directory: $Directory: $!"; ## no critic qw(OTOBO::ProhibitLowPrecedenceOps) # backup application @@ -489,7 +488,6 @@ sub BackupForMigrateFromOTRS { # now adapt the relevant lines # TODO: make this less nasty. Make it nicety. - # TODO: why still warnings from Perl::Critic ?? Maybe the line count is messed up. open my $Adapted, '>', $AdaptedSchemaDumpFile ## no critic qw(OTOBO::ProhibitOpen) or die "Can't open $AdaptedSchemaDumpFile for writing: $!"; ## no critic qw(OTOBO::ProhibitLowPrecedenceOps) say $Adapted "-- adapted by $0";