Php-language-server: Workspace Symbols not including packages in vendor directory

Created on 22 Aug 2017  路  5Comments  路  Source: felixfbecker/php-language-server

OS: Windows 10
VS Code: 1.15.1 x64

I have a Laravel 5.5 app, and when I hit CTRL+T for Workspace Symbol search it doesn't include any files from the vendor directory except Composers own autoloader-files.

Here's some info from the Output->PHP Language Server tab

[Info  - 22:55:32] 74 Packages
[Info  - 22:55:32] Indexing laravel/framework for definitions and static 
..........
[Warn - 22:56:05] Could not compute cache key for laravel/framework
[Info  - 22:56:05] Restored nesbot/carbon:1.22.1 from cache
..........
[Info  - 22:56:07] All 4962 PHP files parsed in 36 seconds. 282 MiB allocated.

Here's without any search input. As you can see it loads my own files (in ./app and root directory) just fine.
code_2017-08-22_23-04-01

Here's when I search for Laravels Illuminate packages.
code_2017-08-22_23-04-39

Here's when I search for Carbon.
code_2017-08-22_23-04-56

Here's when I search for Composer.
code_2017-08-22_23-10-24

Most helpful comment

This is by design. workspace/symbol is designed to return the symbols defined in your own workspace. It would also be very slow to return all matches from dependencies.

That's too bad 馃槙 Sublime handles this really well with no performance issues, would be awesome to have support for it in Code!

Thanks for all your hard work on these packages regardless, incredibly helpful stuff 馃憤

All 5 comments

Hey @adevade,

We did a quick check and this issue looks very darn similar to

This could be a coincidence, but if any of these issues solves your problem then I did a good job :smile:

If not, the maintainers will get to this issue shortly.

Cheers,
Your Friendly Neighborhood ProBot

This is by design. workspace/symbol is designed to return the symbols defined in your own workspace. It would also be very slow to return all matches from dependencies.

This is by design. workspace/symbol is designed to return the symbols defined in your own workspace. It would also be very slow to return all matches from dependencies.

That's too bad 馃槙 Sublime handles this really well with no performance issues, would be awesome to have support for it in Code!

Thanks for all your hard work on these packages regardless, incredibly helpful stuff 馃憤

excuse me, but my project.
If "new Class()" inside one file it working good, but if "new Class()" in other file after include it not working definition.

image

after:

image

@felixfbecker could this be made optional?
We could use the built-in option to exclude the path if necessary.

Was this page helpful?
0 / 5 - 0 ratings