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 108764 - Unable to create new ruby project
Summary: Unable to create new ruby project
Status: RESOLVED WORKSFORME
Alias: None
Product: ruby
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: PC Windows XP
: P2 blocker (vote)
Assignee: Torbjorn Norbye
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-07-03 15:33 UTC by jamespb
Modified: 2007-07-04 19:40 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
screenshot of empty dialog box (348.70 KB, image/gif)
2007-07-03 15:36 UTC, jamespb
Details
messages.log file (22.60 KB, text/plain)
2007-07-03 18:29 UTC, jamespb
Details
userdir.zip (214.08 KB, application/octet-stream)
2007-07-03 18:35 UTC, jamespb
Details
correct userdir - ignore the previous one.gzip (3.08 MB, application/octet-stream)
2007-07-03 19:12 UTC, jamespb
Details

Note You need to log in before you can comment on or make changes to this bug.
Description jamespb 2007-07-03 15:33:15 UTC
Downloaded the latest NetBeans, and when I run "C:\Program Files\NetBeans\bin\nbrubyide.exe" I'm unable to create any
projects.  Everything seems very empty - I've enclosed a screenshot.

Yesterday I saw something similar, and assumed it was because I tried to run directly from the zip file, but this
morning I've definitely copied the contents of netbeans-rubyide-hudson-2715.zip to the real directory.

Product Version: NetBeans Ruby IDE 070703 Java: 1.6.0_01; Java HotSpot(TM) Client VM 1.6.0_01-b06 System: Windows Vista
version 6.0 running on x86; Cp1252; en_US (nbrubyide) Userdir: C:\Users\James\AppData\Roaming\.nbrubyide\dev
Comment 1 jamespb 2007-07-03 15:36:41 UTC
Created attachment 44673 [details]
screenshot of empty dialog box
Comment 2 Torbjorn Norbye 2007-07-03 16:45:30 UTC
Uh oh - that sounds severe.

I just downloaded the same build (2715) and for me it works - both on my existing userdirectory and on a fresh user directory.

Can you try a couple of things to help me narrow this down?

1) Send/attach the error log file(s) in your userdir (userdir/var/log/messages.log*

2) Try starting the IDE on a fresh user directory and bring up the New Project dialog - is it still empty?   Do something like this:

nbrubyide\bin\nbrubyide.exe --userdir C:\nonexistentdir

If that works, would you mind zipping up your userdir and mailing it to me? There shouldn't be any of your own code in the userdirectory (except for 
*.dump files). Any *.dump files in var/log/ can be deleted first (these shouldn't exist, but if the Ruby parser fails on a file, it will stash a copy of the source 
producing the parsing error there along with a stack trace for later analysis).

With the userdir I can hopefully reproduce the problem on my end.   There are two things you can delete first: The whole directory "var/cache/gsf-index" 
inside the userdir,  and any "*.dump" files in "var/log/" (these aren't big 

If the userdir ends up being too large to mail, you can wipe out var/cache/gsf-index/ inside the userdir.

3) If using a fresh userdirectory helper, here's a workaround that may get you productive again:

After saving off the user directory somewhere, you can wipe out some directories in the user dir.

var/cache - delete the whole thing, there are no persistent settings there (that cannot be regenerated)
config/Windows2Local - window system layout etc.

If that doesn't help hopefully I can figure it out by looking at your userdir settings.
Comment 3 jamespb 2007-07-03 18:29:26 UTC
Created attachment 44687 [details]
messages.log file
Comment 4 jamespb 2007-07-03 18:35:29 UTC
Created attachment 44688 [details]
userdir.zip
Comment 5 jamespb 2007-07-03 18:43:40 UTC
C:\Users\James>"\Program Files\NetBeans\bin\nbrubyide.exe" --userdir c:\fakeuser

Problem goes away.  I included my userdir that demonstrates the problem, and I'll just delete it locally - there's
nothing I care about in there.
Comment 6 Torbjorn Norbye 2007-07-03 18:46:40 UTC
I'm wondering if there's something wrong with the installation.

From the log file, it looks like you have a complete NetBeans installation (not just the Ruby stuff) - I'm seeing J2EE, webservices etc. in there.

On the other hand, you're saying you're running "nbrubyide.exe" - which isn't part of NetBeans 6 - thats only for the NetBeans Ruby IDE. (Or was that just a 
typo and you really meant C:\Program Files\NetBeans\bin\netbeans.exe?).

Your version information lists Ruby IDE and a .nbrubyide\dev userdir.

I see nothing unusual in the attached logfile; can you double check which version of the IDE you were running and that you attached the user directory / log 
files corresponding to the IDE that has the problem? (The About box will list the userdir being used for the currently running IDE; they are different for 
NetBeans 6 and the Ruby IDE since they can have different sets of enabled/disabled plugins etc.).
Comment 7 jamespb 2007-07-03 18:48:28 UTC
Just deleted my userdir, and that didn't solve the problem - I still get a blank create project dialog like the
screenshot here.
Comment 8 jamespb 2007-07-03 18:58:16 UTC
I wonder if I'm looking at the right userdir.

Starting from a command line and specifying the --userdir option works consistently.

Double-clicking the netbeans icon (the way I used to start it) gives the problem.

Running from the command line creates the specified userdir.  Double-clicking does not create c:\Users\James\.netbeans,
which is what I thought my userdir defaulted to.  It was there previously, and that's the userdir I uploaded here.  I
deleted it thinking NetBeans would automatically rebuild it for me, but that doesn't happen.
Comment 9 jamespb 2007-07-03 19:06:35 UTC
My normal way of installing is to grab netbeans-rubyide-hudson-2715.zip (or the latest equivalent), blow away 
C:\Program Files\NetBeans\, and copy the contents of netbeans-rubyide-hudson-2715.zip into that location.  That's what
I'm running now; as far as I know there aren't any other netbeans setups on this machine.

I gave you the wrong userdir - I'll include the right one.

Here's the version info:

Product Version: NetBeans Ruby IDE 070703 Java: 1.6.0_01; Java HotSpot(TM) Client VM 1.6.0_01-b06 System: Windows Vista
version 6.0 running on x86; Cp1252; en_US (nbrubyide) Userdir: C:\Users\James\AppData\Roaming\.nbrubyide\dev
Comment 10 jamespb 2007-07-03 19:10:09 UTC
"On the other hand, you're saying you're running "nbrubyide.exe" - which isn't part of NetBeans 6 - thats only for the
NetBeans Ruby IDE. (Or was that just a 
typo and you really meant C:\Program Files\NetBeans\bin\netbeans.exe?)."

Not a typo, that's a cut-and-paste of the command I ran.
Comment 11 jamespb 2007-07-03 19:10:12 UTC
"On the other hand, you're saying you're running "nbrubyide.exe" - which isn't part of NetBeans 6 - thats only for the
NetBeans Ruby IDE. (Or was that just a 
typo and you really meant C:\Program Files\NetBeans\bin\netbeans.exe?)."

Not a typo, that's a cut-and-paste of the command I ran.
Comment 12 jamespb 2007-07-03 19:12:50 UTC
Created attachment 44689 [details]
correct userdir - ignore the previous one.gzip
Comment 13 jamespb 2007-07-03 19:15:31 UTC
When I deleted the right userdir (the one in C:\Users\James\AppData\Roaming\.nbrubyide) and restarted, the problem went
away.  I can now double-click on the netbeans icon and get a functional system that can create Ruby projects.

Product Version: NetBeans Ruby IDE 070703 Java: 1.6.0_01; Java HotSpot(TM) Client VM 1.6.0_01-b06 System: Windows Vista
version 6.0 running on x86; Cp1252; en_US (nbrubyide) Userdir: C:\Users\James\AppData\Roaming\.nbrubyide\dev
Comment 14 jamespb 2007-07-03 19:19:35 UTC
Just to clarify (and so I don't confuse myself) - your statement:

"From the log file, it looks like you have a complete NetBeans installation (not just the Ruby stuff) - I'm seeing J2EE,
webservices etc. in there."

was caused by me giving you an unrelated log file from some unknown/random previous attempt to run netbeans.
Comment 15 Torbjorn Norbye 2007-07-04 18:06:09 UTC
Thanks - with your userdirectory I'm able to reproduce the problem! 

Now to figure out how the userdir got into that state in the first place....
Comment 16 Torbjorn Norbye 2007-07-04 18:27:39 UTC
The reason nothing shows up in the Projects menu is that all the Ruby modules are disabled;

% ls .nbrubyide/dev/config/Modules
org-jruby-distro.xml_hidden                             
org-netbeans-modules-gsf.xml_hidden                    
org-netbeans-modules-ruby-railsprojects.xml_hidden
...

The big question is how they came to be disabled. My guess is that at some point there was an incompatible or missing module version, and at that point 
the IDE disables any modules downstream that depend on it. This usually brings up a dialog asking the user about it at startup though.  There's no record 
of this happening in the logs which only contains 3 runs.  Do you remember anything unusual happening at startup - anything about module 
incompatibilities or anything like that?

This bug is likely the result of some incompatible change that happened across a couple of builds, and running one of those builds left some state around 
which continues to cause problems.  Put another way, I don't think this issue will happen with big milestone builds. 

Downgrading the issue a bit for now since it doesn't seem to happen with current builds.
Comment 17 jamespb 2007-07-04 19:13:36 UTC
I had thought it might have something to do with running netbeans directly from the zip file
(http://www.netbeans.org/issues/show_bug.cgi?id=108708), but I couldn't repro the problem that way.

I don't remember any warning messages from NetBeans.

I'll let you know if it happens again, but if I were you I'd just close this bug since I can't repro it and it's not
obvious from the logs.  Seems like if it's a continuing issue it'll get reported again.
Comment 18 Torbjorn Norbye 2007-07-04 19:40:43 UTC
Ok, sounds good. Thanks for all the followup info.