config.php
<?php
/**
* This configuration will be read and overlaid on top of the
* default configuration. Command line arguments will be applied
* after this file is read.
*/
return [
"target_php_version" => '8.3',
'directory_list' => [
'src',
'vendor/symfony/console',
'vendor/symfony/dom-crawler',
'vendor/guzzlehttp/guzzle',
'vendor/psr/http-message/',
],
"exclude_analysis_directory_list" => [
'vendor/'
],
'plugins' => [
'AlwaysReturnPlugin',
'DollarDollarPlugin',
'DuplicateArrayKeyPlugin',
'DuplicateExpressionPlugin',
'PregRegexCheckerPlugin',
'PrintfCheckerPlugin',
'SleepCheckerPlugin',
// Checks for syntactically unreachable statements in
// the global scope or function bodies.
'UnreachableCodePlugin',
'UseReturnValuePlugin',
'EmptyStatementListPlugin',
'LoopVariableReusePlugin',
],
];
estrutura de pastas:
erro:
analyze ████████████████████████████████████████████████████████████ 100.0% 33MB/34MB
src/Buscador.php:10 PhanUndeclaredTypeProperty Property \Alura\BuscadorCursos\Buscador->httpClient has undeclared type \GuzzleHttp\ClientInterface
src/Buscador.php:11 PhanUndeclaredTypeProperty Property \Alura\BuscadorCursos\Buscador->crawler has undeclared type \Symfony\Component\DomCrawler\Crawler
src/Buscador.php:13 PhanUndeclaredTypeParameter Parameter $crawler has undeclared type \Symfony\Component\DomCrawler\Crawler
src/Buscador.php:13 PhanUndeclaredTypeParameter Parameter $httpClient has undeclared type \GuzzleHttp\ClientInterface
src/Buscador.php:22 PhanUndeclaredClassMethod Call to method request from undeclared class \GuzzleHttp\ClientInterface
src/Buscador.php:26 PhanUndeclaredClassMethod Call to method addHtmlContent from undeclared class \Symfony\Component\DomCrawler\Crawler
src/Buscador.php:28 PhanUndeclaredClassMethod Call to method filter from undeclared class \Symfony\Component\DomCrawler\Crawler
infoshop@Mac-mini-de-Infoshop buscador-cursos-alura % ./vendor/bin/phan --allow-polyfill-parser src/Buscador.php
Por que ainda não é reconhecido as classes, poderia me ajudar ? agradeço.