Vscode-intelephense: Error: Undefined type after update extension

Created on 18 Aug 2020  路  5Comments  路  Source: bmewburn/vscode-intelephense

Describe the bug
After update extension, I get this error
Error: Undefined type 'PhpZip\ZipFile'.

To Reproduce
I use an example of this library
PhpZip

require 'vendor/composer/vendor/autoload.php';
$zipFile = new \PhpZip\ZipFile();
$zipFile->setCompressionLevel(\PhpZip\Constants\ZipCompressionLevel::SUPER_FAST);
$zipFile->addDirRecursive($_SESSION['reportPath'], null, \PhpZip\Constants\ZipCompressionMethod::STORED);
$zipFile->saveAsFile($filePath);
$zipFile->close();

Expected behavior
Not showing error, library it's working with no problem
I include wrong way?

Screenshots
Screenshot from 2020-08-18 15-03-14

Platform and version
Ubuntu 19.10 and Intelephense 1.5.4

Most helpful comment

There's a default intelephense.files.exclude glob now to exclude nested vendor files **/vendor/**/vendor/** does removing this help?

All 5 comments

I'm unable to reproduce this. Does a reindex fix it? ctrl + shift + p -> Index workspace

Does a reindex fix it? ctrl + shift + p -> Index workspace

No, Not work

There's a default intelephense.files.exclude glob now to exclude nested vendor files **/vendor/**/vendor/** does removing this help?

There's a default intelephense.files.exclude glob now to exclude nested vendor files **/vendor/**/vendor/** does removing this help?

Yes , its Help.

I was having the same problem with Throwable, but the reindex did fix it.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ghost picture ghost  路  3Comments

vanasis picture vanasis  路  4Comments

mushmelty picture mushmelty  路  4Comments

9brada6 picture 9brada6  路  3Comments

muuvmuuv picture muuvmuuv  路  4Comments