Almost every day PHPStorm "forgets" all classes und functions until "invalidate cache"

Answered

Every day when I start PHPStorm, I have to invalidate the cache, because otherwise PHPStorm dont know any PHP-Function or any of my Classes. After the invalidation and restart of PHPStorm, everything works fine. Here is a Screenshot that shows what I mean: 

Version: 2017.2.4. Build #PS-172.4155.41
JRE: 1.8.0_152-release-915-b11 amd64
JVM: OpenJDK 64-Bit Server VM
OS: Ubuntu 16.04 LTS

12 comments

Solved! It was the .gitignore plugin. Uninstalled it and now everything works perfect.

3

Thanks for the reply!

0) No, "Navigate | File" or "| Class" doesn't work. "Search everywhere" works.

1) ".ignore", "ANSI Highlighter", "Dash", "Karma", "PHP Annotations", "PHP Toolbox", "Scroll from Source" and "Symfony Plugin". Everything up2date

2) No

3) Every Morning. Around 16 Hours after shutdown

4) Yes

5) Yes

1

I have the same issue: When i start my computer (OSX 10.13.1) and launch PHPStorm (2017.2.4) it does not recognise any functions/classes etc from my project or PHP itself.

The difference with Sk is that in my IDE the search function can't find anything.
I need to invalidate the cache and restart the IDE to make it work again. It keeps working for the rest of the day.

The only custom plugin that i am using is .gitignore. Sk is also using this, so i removed it and i will check if this will solve the issue.

1

It very could be .gitignore plugin for 2017.2.x version -- at very least that's what I see from similar kind of threads/tickets (disabling it helps in most cases) -- https://youtrack.jetbrains.com/issue/WI-37873.

1

Also have this problem in Webstorm 2017.2 (and I am using the .gitignore plugin), have to invalidate caches and restart after every exit and open. Has anyone contacted the authors of .gitignore? I will file a ticket on their github.

Please note that from a user experience perspective, we are nagged with "A plugin has been detected to support this file" when viewing our .gitignore. Thus we install it. Then it breaks the IDE's cache. Consider withholding the nagging plugin prompts if you discover the extensions break features of the IDE.

1

Hi there,

It might be related to the 3rd party (not bundled by default) plugins you are using ... or possibly it's OS/computer specific issue.

I personally do not have such issue (and never had) even though I have quite a few custom plugins installed. But you are not first person who saying that IDE stops recognizing the code on next launch on rather regular basis (although I have seen only few complains here on Forum and Issue Tracker).. that's why plugin or OS/hardware might be the reason.

0) I assume then when this happens the "Navigate | File" and alike may not be able to find some existing files as well?

1) Can you please list your custom plugins?

2) Any symbolic links or alike (e.g. DropBox sync/network location) used in places where IDE stores the settings/indexes?

3) How long does it take for IDE to stop recognizing the code?

4) Can you run for a day (or how long it takes for previous Q) without custom plugins enabled? That at least would give an answer if it's plugin related or something else. I've noticed that it's a Symfony project ...

5) I've mentioned possible hardware issue (since this problem is not affecting a lot of people) -- can you run some hardware tests for your RAM and HDD?

 

Possibly related ticket (issues with indexes): https://youtrack.jetbrains.com/issue/WI-37873

0

Oh, after writing the last comment and switching back to PHPStorm, everything was fine. But there was no process running (like Indexing or similar)

0

See if you can notice anything interesting in idea.log file (Help | Show Log in...)

Try #5 and then #4 (if you can)

If anything -- that ticket that I have mentioned may be a good place to comment (if you find any pattern).

If you find something worthy in logs or some pattern (e.g. plugin/etc) -- maybe worth using "Submit a request" link at the top of this page to submit a Support ticket (where you can privately attach any files etc) -- it's better to speak to support team than wait until somebody (e.g. another PhpStorm user like me) will reply on public forum.

0

After using 2017.3 EAP for a while now, I don't have this issue anymore. Seems like it's fixed now.

And I don't experienced any others issues with this EAP-Version. Maybe give it a try?

0

@Josh Suitable plugin detection is quiet basic - it just lets you know the option and nothing else.

.ignore plugin is not available for installation via Settings/Preferences | Plugins at the moment just because of these issues. Therefore plugin notifications should not appear as well.

Maintainers recently updated it and fixed the issue - we now perform additional tests to confirm that and once this will be done, it will appear again.

0

I have been having the same issue on phpStorm (2017.2.4) and MacOS (10.13.1) and upgrading to the most recent version of .ignore (2.3.2) did not fix it for me.

0

I have to say the same as Eric, with minor difference on a version bump on macOS,10.13.2.

I've uninstalled .ignore plugin, but need to wait a few days to figure out whether it'll help out or not.

0

Please sign in to leave a comment.