-
-
Notifications
You must be signed in to change notification settings - Fork 738
Rector stoppped to parse my files #7784
Copy link
Copy link
Closed
Description
This morning probably something happened, but my rector installation is no more parsing file
This is composer.json
{
"require-dev": {
"rector/rector": "^0.14.8",
"nikic/php-parser": "^4.15"
},
"autoload-dev": {
"psr-4": {
"Rules\\": "rules"
}
},
"require": {
"rector/rector-debugging": "dev-main"
}
}
Running against a prova.php file is not changing nothing at all. Also --debug flag is not giving me anything usefull
vendor\bin\rector.bat process .\prova.php --dry-run --debug
.\prova.php
[OK] Rector is done!
This is my prova.php file
<?
function tbl_delete($table,$id) {
$link=mysql_connect("localhost",USER,PWD);
mysql_select_db(DB) or die("No connection");
$query="DELETE FROM $table WHERE id=$id";
$result=mysql_query($query) or die("Query Error");
}
rector.php is
return static function (RectorConfig $rectorConfig): void {
$rectorConfig->phpVersion(PhpVersion::PHP_56);
$rectorConfig->rule(AddLinkParamToMysqlQuery::class);
$rectorConfig->rule(MysqlAssignToMysqliRector::class);
}
Where first of 2 rules is a custom one.
The custom one is parsing FuncCall and it should be printing file name at each invocation, just for debug.
I cannot diagnose the problem... Why nothing touched ?
PHP Version
php -v
PHP 8.1.2 (cli) (built: Jan 19 2022 10:13:52) (NTS Visual C++ 2019 x64)
Copyright (c) The PHP Group
Zend Engine v4.1.2, Copyright (c) Zend Technologies
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels