Find your content:

Search form

You are here

Any way to prevent stale error messages / autocomplete failure on Force.com IDE startup?

 
Share

I have used the Force.com IDE for years now. I'm currently using the Summer 12 (latest, correct?) standalone version, although I also tried the Eclipse plugin against 3.6.

I have recently started to see odder-than-normal behavior with the IDE and I'm wondering if anyone has a fix. I think the issues may be related, but I can't for the life of me find one. I've spent hours trying to fix this, including de-install/re-install of multiple IDE and JDK versions, and still it persists. I'm pretty experienced in troubleshooting Eclipse issues, having used the Java IDE for over 10 years, so I don't think I'm missing anything obvious.

Problem 1: stale error messages on startup

Frequently, when I startup the IDE after it being (normally) shut down, I receive an odd set of code-related error messages. The messages themselves I may have received in past versions of my code, but the set I see upon startup is NEVER valid. (I never shut down the IDE while I have compilation errors, I only use this IDE and workspace to develop, I am the only person modifying these specific orgs).

The solution is to do a Force.com > Refresh, and this seems to fix the problem. However, it takes a long time and seems like a very fixable issue.

Here's a partial screenshot of what I got today when I fired up the IDE:

enter image description here

Let me emphasize: I have not had near this many concurrent save errors in recent memory. I had shut down the IDE just a few hours earlier with a fully compiled, happy codebase. Some of the above errors didn't even ring a bell, but that could be developerzoning - I suspect that they are genuine errors I had in my IDE cache at some point.

Problem 2: technically a separate issue, although as mentioned I think it may be related.

In one of my orgs, auto-complete recently stopped working after upgrading to Force IDE v25. Not only that, but every time I open a file, my IDE hangs for a few seconds before giving a non-specific error message that appears to come from the metadata API. The same duration hang occurs while editing code from time to time, seeming to be from trying to get some lookahead completes for autocomplete. It's VERY annoying.

Here's a screenshot of what happens pretty much every time I open a file in this org:

enter image description here

As I said, I have done MANY de-install/re-install of both IDE and JDK; I have used totally fresh workspaces; both of these problems persist in both.

In case it helps, this is a partner developer edition which also may be relevant since it does not occur in my non-partner DE orgs.

I'm at the end of my tether, but short of trying a fresh machine was hoping someone has any ideas.


Attribution to: jkraybill

Possible Suggestion/Solution #1

When I checkout a new project from a repo it starts of with errors such as your mostly due to the server having newer timestamps. In that case rather then a "Force.com > Refresh" I simply right click on the error header node and delete it.

TIP: use the 'Project Explorer' (instead of Navigator/Package Explorer) view pane to have the overlay icons with errors/warnings to know easier when a push failed.

Checked out project delete all errors


Attribution to: Daniel Sokolowski

Possible Suggestion/Solution #2

I have an eclipse instance bound to source control (as well as my org). What I've found is every time I get the latest source from source control and try to edit and save a class, I get a raft of errors like you. I've found that doing 'Clean' Project (with Start a Build Immediately unchecked) has gotten rid of my problem, coz potentially it clears some kinda cache which the IDE holds.

I'm wondering if your second problem has anything to do with your Internet proxy acting up, if you're using one.


Attribution to: techtrekker

Possible Suggestion/Solution #3

Found the solution, thanks to an unbelievably efficient Salesforce support case. I opened a case earlier today, it got assigned in a few hours, and I got the resolution within a few minutes. I'm impressed, given the nature of my issue.

Anyway, it turns out that this error was occurring because I had the "Knowledge User" checkbox checked on one of my user records, but I hadn't enabled Knowledge. (So probably don't ever do this.) I never would have guessed that was the cause.

Simply enabling knowledge instantly fixed my IDE issue. According to support, also disabling the "knowledge user" checkbox would have worked too, which sounds plausible but enabling knowledge felt like a better permanent solution to me.

This fixed my open/auto-complete issue immediately, which was the much more productivity-affecting one for me; I'll know in a day or two if the stale error messages issue has gone away too.

TL;DR: don't ever click the "Knowledge User" checkbox on a User without enabling Knowledge, or Eclipse (and possibly some chunk of your metadata API access) will break.


Attribution to: jkraybill
This content is remixed from stackoverflow or stackexchange. Please visit https://salesforce.stackexchange.com/questions/2072

My Block Status

My Block Content