This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 238811 - Project stuck in Initializing and can't be closed or opened.
Summary: Project stuck in Initializing and can't be closed or opened.
Status: RESOLVED INCOMPLETE
Alias: None
Product: projects
Classification: Unclassified
Component: Generic Projects UI (show other bugs)
Version: 7.3.1
Hardware: Macintosh Mac OS X
: P2 normal (vote)
Assignee: Milos Kleint
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-26 09:56 UTC by KPetersF
Modified: 2014-01-27 13:18 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
IDE log (80.69 KB, text/plain)
2013-11-26 09:56 UTC, KPetersF
Details
JSTACK dump (13.55 KB, text/rtf)
2013-11-26 10:31 UTC, KPetersF
Details
Screenshot (14.86 KB, image/png)
2013-11-26 11:48 UTC, KPetersF
Details
folders (375.06 KB, image/png)
2013-11-27 09:57 UTC, KPetersF
Details
projectui (15.14 KB, application/octet-stream)
2013-11-27 10:06 UTC, KPetersF
Details

Note You need to log in before you can comment on or make changes to this bug.
Description KPetersF 2013-11-26 09:56:35 UTC
Product Version = NetBeans IDE 7.3.1 (Build 201306052037)
Operating System = Mac OS X version 10.6.8 running on x86_64
Java; VM; Vendor = 1.6.0_65
Runtime = Java HotSpot(TM) 64-Bit Server VM 20.65-b04-462
Comment 1 KPetersF 2013-11-26 09:56:39 UTC
Created attachment 142581 [details]
IDE log
Comment 2 KPetersF 2013-11-26 09:57:36 UTC
A project is stuck initializing and I can't close it. Right clicking on its name gives greyed out options. I successfully reopened the same project so I can work on it like that but the other one is still there and I can't get rid of it.
Comment 3 Milos Kleint 2013-11-26 10:13:03 UTC
I will need at least a thread dump to see if some threads deadlocked or something similar.

What project type? is it reproducible? what filesystem, any symbolic links? etc.. the ore details you can provide, the likely we will be able to fix, right now there's nothing to start the evaluation unfortunately.
Comment 4 KPetersF 2013-11-26 10:17:50 UTC
IT's a PHP project and it's the first time I've had it happen. It doesn't go away with restarts or even reboots so it's constantly just there in my projects list. I'm not so used to netbeans where do I find a thread dump?
Comment 5 Milos Kleint 2013-11-26 10:19:52 UTC
(In reply to KPetersF from comment #4)
> IT's a PHP project and it's the first time I've had it happen. It doesn't go
> away with restarts or even reboots so it's constantly just there in my
> projects list. I'm not so used to netbeans where do I find a thread dump?

http://wiki.netbeans.org/GenerateThreadDump
Comment 6 KPetersF 2013-11-26 10:31:51 UTC
Created attachment 142585 [details]
JSTACK dump

I hope this helps.
Comment 7 KPetersF 2013-11-26 11:48:13 UTC
Created attachment 142587 [details]
Screenshot

Greyed out options
Comment 8 Milos Kleint 2013-11-27 09:27:07 UTC
can you please also attach the Preferences/org/netbeans/modules/projectui.properties file from your userdirectory? see http://wiki.netbeans.org/FaqWhatIsUserdir
Comment 9 KPetersF 2013-11-27 09:41:40 UTC
There is no
Comment 10 KPetersF 2013-11-27 09:44:02 UTC
(In reply to KPetersF from comment #9)
> There is no

There is no 'org' folder under my Preferences folder, neither is there a projectui.properties file in my modules folder of the netbeans user directory.
Comment 11 Milos Kleint 2013-11-27 09:51:32 UTC
if you ever had any projects opened, it has to be there. Otherwise no projects would show up upon restart.

ahh, if you are using project groups, there could be also under Preferences/org/netbeans/modules/projectui/groups/
Comment 12 KPetersF 2013-11-27 09:57:44 UTC
Created attachment 142631 [details]
folders

I really can't see a 'org' folder, not the projectui.properties file
Comment 13 Milos Kleint 2013-11-27 10:02:28 UTC
Comment on attachment 142631 [details]
folders

it's under application support/netbeans/7.3.1/config/preferences
Comment 14 KPetersF 2013-11-27 10:06:14 UTC
Created attachment 142632 [details]
projectui
Comment 15 Milos Kleint 2013-12-05 15:40:06 UTC
There's 2 related but separate problems here.

1. somehow a project didn't load properly and a ghost item stayed around.
2. upon restart, the duplicate items (ghost and correct project) keep on appearing without a possibility to close the ghost.

Correct?
Comment 16 KPetersF 2013-12-05 15:42:13 UTC
Indeed. Right clicking the 'ghost' item has all greyed out options. And opening the ghost item is just keeps saying "Initializing..."

The other project works without a problem.
Comment 17 Milos Kleint 2013-12-05 15:47:37 UTC
a workaround for you is to close the IDE and delete the  config/Preferences/org/netbeans/modules/projectui.properties file (editing could also work but is tricky). After restarting the IDE, reopen the projects.
Comment 18 KPetersF 2013-12-05 16:09:15 UTC
Yep it's gone now, thanks. Still no clue how it happened though.
Comment 19 Milos Kleint 2013-12-10 14:15:03 UTC
given your projectui.properties file, I've tried to create a similar setup on my computer (2 entries for one location/project) so that I can start changing the code to discard one of the entries.

However whenever I've restarted the IDE with the 2 same projects opened, one of them eventually disappeared. I've tested both with simple java only IDE and also with a full IDE (with ergonomics/feature on demand).

I've tried with latest sources, not 7.4. I'm not aware of any work in project loading area that could be relevant to this done for 8.0 however.

The 'ghost' project however kept on appearing on subsequent restarts for a while (until the projects are actually loaded and the 'ghost' gets removed.

Same effect appears when the projectui.properties file gets changed manually to point to folders that don't exist on disk. Or by deleting these folders while the IDE is down. We will show the skeleton nodes for these, but since there's nothing to be loaded, we remove the nodes after the loading loop finishes.

The effect disappears when there data gets overwritten by opening some other projects.. So eg. if the 'ghost' project is persisted with index of 3 in the projectui.properties file and the user opens a new project which then overwrites the entry in the file for index of 3, the 'ghost' stops appearing.
Comment 20 Milos Kleint 2013-12-10 14:23:46 UTC
a long observed side effect of this is that when you open a project, then rename it, upon restart the old name will keep on showing until the project isn't loaded. That will keep on happening until you open or close one of the projects (then the list to store is regenerated)
Comment 21 Milos Kleint 2013-12-10 16:37:04 UTC
the possibly important line in messages.log is this one:
WARNING [org.netbeans.modules.project.ui.OpenProjectList]: LazyProjects remain visible

That implies that even though OpenProjectList.LoadOpenedProject.run() went past loadOnBackground(), when reaching ProjectsRootNode.checkNoLazyNode(), there's still some LazyProject instances in the child nodes.

the ProjectsRootNode children keys are however replaced when PROPERTY_OPEN_PROJECTS arrives. That's fired before checkNoLazyNode() in  updateGlobalState()

however since issue 180155, the recalculation of children keys happens in async manner.

the run() method itself is running in AWT apparently via the WindowManager.getDefault().invokeWhenUIReady() call.


So in some setups it can print this message when we get processed the AWT faster than the RP thread, but I was not able to find a piece of code that would be affected apart from the log message itself.
Comment 22 KPetersF 2013-12-17 08:21:17 UTC
The ghost project returned and it's the same deal as before, I've also just noticed that the correct opened project i have in the list has stopped updating contents. Deleting /adding / editing files does not update in the project view list untill I close and open the working project again
Comment 23 Milos Kleint 2013-12-17 08:27:34 UTC
(In reply to KPetersF from comment #22)
> The ghost project returned and it's the same deal as before, I've also just
> noticed that the correct opened project i have in the list has stopped
> updating contents. Deleting /adding / editing files does not update in the
> project view list untill I close and open the working project again

is it the same project again? is there something different in this project compared to the others you have?
Comment 24 KPetersF 2013-12-17 08:30:44 UTC
It is the exact same project  as before, and with the same setup as all my other projects so I'm not sure of the reason why it's acting up like this.
Comment 25 KPetersF 2013-12-17 08:36:14 UTC
I have also just noticed that right clicking on a folder and attempting to create a new file in the folder places the new file in the root of the project rather than the folder I clicked on..
Comment 26 Milos Kleint 2014-01-27 11:27:22 UTC
I've tried to go to the extreme, created www/famous-CRM project in my /Users/mkleint mac homedir, then took the projectui.properties file and manually copy&pasted it 20 times. So I should have like 20 duplicates in the UI, however  no matter how many times I tried I've always ended up with just one entry and no "ghost" project.
Comment 27 KPetersF 2014-01-27 11:41:35 UTC
I didn't have multiple projects it was just 1 folder, still unsure how it happened and now I have a new mac and updated installations so I can't recreate it anymore myself as it seems to be fixed.

I can't give you any further information anymore as I no longer have that mac in my possession. Thanks for looking into it however.
Comment 28 Milos Kleint 2014-01-27 13:18:42 UTC
ok, let me close as incomplete then. please reopen with additional details