Auto-Import Broken

Hey all, been using Idea for a couple years now and loving it. Running on Ubuntu 7.10 with JDK 1.6.0_04.

Unfortunately, Idea has recently stopped automatically recognizing even common classnames to import. For instance, if I start up and create a new project from scratch, "List" doesn't automatically get imported, and hitting Ctrl-Enter doesn't bring up any options. Organizing Imports also has no effect.

The catalyst for this problem seems to be that I recently created a new project B that relies on some common modules from project A. The modules relied on project libraries like Spring 2.0.7, etc that were stored in the Project. I wanted project B to use the new version of Spring, so I added the modules as a dependency, and created project libraries with the same generic name "Spring" that actually contained the Spring 2.5.1 jars. This links fine and works when deployed, but I think something caused Intellij to get confused. The libraries get imported correctly if I copy source containing the classname from a different file that has the library imported. Also, if I manually enter the import statement, it works fine.

Relevant settings:
Insert Imports: "Ask"
Show Import popup: checked
Use single class import: checked
Insert imports for inner classes: not checked
Optimize imports on the fly: checked
Add unambiguous imports on the fly: checked

Possible ideas?
1) JDK problem?
2) some global classpath issue in IntelliJ? I have no global libraries specified...
3) a setting that I'm not seeing somewhere?

Any ideas? Thanks in advance, this is driving me batty.

Comment actions Permalink

i have exactly the same problem and i am also using IntelliJ for years. I am running 7.0.2 now on Mac OS X. Any Ideas?


Comment actions Permalink

I am seeing this problem as well. Partner using the exact same version of IDEA (7.0.2, build 7590) on the same OS (Suse Linux) is not seeing the issue. Wierd.

Comment actions Permalink

The fix. I waxed my System Cache for IntelliJ and the problem went away. If you ar eon Linux, you can find this file in the USER_HOME_DIR/.Intellij/system.

Comment actions Permalink

That did it. Thanks, Kevin!


Please sign in to leave a comment.