[2.0.0-alpha.3] Failed to fix: Reached maximum number of loops
Xerkus opened this issue · 1 comments
Xerkus commented
This file causes maximum number of loops reached error with 2.0.0-alpha.3:
https://github.com/zendframework/zend-mvc/blob/d83d57e2e64e240e94efcc43d5b1483919cb65a0/src/View/Http/InjectTemplateListener.php
Related dependencies:
dealerdirect/phpcodesniffer-composer-installer v0.5.0
slevomat/coding-standard 4.8.7
squizlabs/php_codesniffer 3.4.0
webimpress/coding-standard dev-master dffb652
zendframework/zend-coding-standard 2.0.0-alpha.3
Offending part by the looks of it:
https://github.com/zendframework/zend-mvc/blob/d83d57e2e64e240e94efcc43d5b1483919cb65a0/src/View/Http/InjectTemplateListener.php#L108-L115
if (// Allow disabling rule by setting value to false since config
// merging have no feature to remove entries
false == $replacement
// Match full class or full namespace
|| ! ($controller === $namespace || strpos($controller, $namespace . '\\') === 0)
) {
continue;
}
=> Fixing file: 0/38 violations remaining [made 45 passes]... * fixed 0 violations, starting loop 46 *
WebimpressCodingStandard\Sniffs\Commenting\PlacementSniff (line 41) replaced token 838 (T_COMMENT) "//·Allow·disabling·rule·by·setting·value·to·false·since·config\n" => "·//·Allow·disabling·rule·by·setting·value·to·false·since·config\n"
=> Fixing file: 1/38 violations remaining [made 46 passes]... * fixed 1 violations, starting loop 47 *
**** PHP_CodeSniffer\Standards\PSR2\Sniffs\ControlStructures\ControlStructureSpacingSniff (line 105) has possible conflict with another sniff on loop 45; caused by the following change ****
**** replaced token 838 (T_WHITESPACE) "·//·Allow·disabling·rule·by·setting·value·to·false·since·config\n" => "//·Allow·disabling·rule·by·setting·value·to·false·since·config\n" ****
**** ignoring all changes until next loop ****
=> Fixing file: 0/38 violations remaining [made 47 passes]... * fixed 0 violations, starting loop 48 *
PHP_CodeSniffer\Standards\PSR2\Sniffs\ControlStructures\ControlStructureSpacingSniff (line 105) replaced token 838 (T_WHITESPACE) "·//·Allow·disabling·rule·by·setting·value·to·false·since·config\n" => "//·Allow·disabling·rule·by·setting·value·to·false·since·config\n"
=> Fixing file: 1/38 violations remaining [made 48 passes]... * fixed 1 violations, starting loop 49 *
**** WebimpressCodingStandard\Sniffs\Commenting\PlacementSniff (line 41) has possible conflict with another sniff on loop 47; caused by the following change ****
**** replaced token 838 (T_COMMENT) "//·Allow·disabling·rule·by·setting·value·to·false·since·config\n" => "·//·Allow·disabling·rule·by·setting·value·to·false·since·config\n" ****
**** ignoring all changes until next loop ****
weierophinney commented
This repository has been closed and moved to laminas/laminas-coding-standard; a new issue has been opened at laminas/laminas-coding-standard#8.