FeaturesPluginsDocs & SupportCommunityPartners

NetBeans Forums

 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
  

NetBeans 6.5 and JRuby 1.2.0

 
Post new topic   Reply to topic    NetBeans Forums -> Ruby Users
View previous topic :: View next topic  
Author Message
Lars Frantzen
Posted via mailing list.





PostPosted: Wed May 20, 2009 1:25 pm    Post subject: NetBeans 6.5 and JRuby 1.2.0 Reply with quote

Hello,

I installed JRuby on my Ubuntu laptop and used the 'Autodetect
Platforms' feature of NetBeans to detect it, which seemed to work fine.

But when I try to run a JRuby project I get:

Exception in thread "main" java.lang.NoClassDefFoundError: org/jruby/Main
Caused by: java.lang.ClassNotFoundException: org.jruby.Main
...

Would be happy for every hint!

Cheers,
Lars
Back to top
Erno Mononen
Posted via mailing list.





PostPosted: Wed May 20, 2009 2:01 pm    Post subject: NetBeans 6.5 and JRuby 1.2.0 Reply with quote

Hi Lars,

Can you try whether the following works from the command line:

<jruby-1.2.0 install dir>bin/jruby -v


Erno



Lars Frantzen wrote:
Quote:
Hello,

I installed JRuby on my Ubuntu laptop and used the 'Autodetect
Platforms' feature of NetBeans to detect it, which seemed to work fine.

But when I try to run a JRuby project I get:

Exception in thread "main" java.lang.NoClassDefFoundError: org/jruby/Main
Caused by: java.lang.ClassNotFoundException: org.jruby.Main
...

Would be happy for every hint!

Cheers,
Lars






Back to top
Lars Frantzen
Posted via mailing list.





PostPosted: Fri May 22, 2009 12:26 pm    Post subject: NetBeans 6.5 and JRuby 1.2.0 Reply with quote

Hi Erno,

thanks for the reply.

Erno Mononen wrote:
Quote:
Can you try whether the following works from the command line:

<jruby-1.2.0 install dir>bin/jruby -v

yes, it is installed in /usr/local/jruby-1.2.0/ and there is a symlink
to the jruby executable in /usr/local/bin.

I get:

jruby -v
jruby 1.2.0 (ruby 1.8.6 patchlevel 287) (2009-03-16 rev 9419) [amd64-java]

Cheers,
Lars

Quote:


Erno



Lars Frantzen wrote:
Quote:
Hello,

I installed JRuby on my Ubuntu laptop and used the 'Autodetect
Platforms' feature of NetBeans to detect it, which seemed to work fine.

But when I try to run a JRuby project I get:

Exception in thread "main" java.lang.NoClassDefFoundError: org/jruby/Main
Caused by: java.lang.ClassNotFoundException: org.jruby.Main
...

Would be happy for every hint!

Cheers,
Lars












Back to top
Lars Frantzen
Posted via mailing list.





PostPosted: Mon May 25, 2009 2:24 pm    Post subject: NetBeans 6.5 and JRuby 1.2.0 Reply with quote

Hi,

I could fix it by manually adding the JRuby 1.2.0 platform. Something
seems to go wrong when doing the autodetect.

Cheers,
Lars

Erno Mononen wrote:

Lars Frantzen wrote:
Quote:
Hi Erno,

thanks for the reply.

Erno Mononen wrote:
Quote:
Can you try whether the following works from the command line:

<jruby-1.2.0 install dir>bin/jruby -v

yes, it is installed in /usr/local/jruby-1.2.0/ and there is a symlink
to the jruby executable in /usr/local/bin.

I get:

jruby -v
jruby 1.2.0 (ruby 1.8.6 patchlevel 287) (2009-03-16 rev 9419) [amd64-java]

Cheers,
Lars

Quote:

Erno



Lars Frantzen wrote:
Quote:
Hello,

I installed JRuby on my Ubuntu laptop and used the 'Autodetect
Platforms' feature of NetBeans to detect it, which seemed to work fine.

But when I try to run a JRuby project I get:

Exception in thread "main" java.lang.NoClassDefFoundError: org/jruby/Main
Caused by: java.lang.ClassNotFoundException: org.jruby.Main
...

Would be happy for every hint!

Cheers,
Lars

















Back to top
Erno Mononen
Posted via mailing list.





PostPosted: Mon May 25, 2009 3:13 pm    Post subject: NetBeans 6.5 and JRuby 1.2.0 Reply with quote

Hi Lars,

Glad to hear you found a way to add it.

I apparently forgot to reply to this thread earlier (the other thread
about a similar issue got me to forgot this one). Anyway, what I wanted
to reply is that the log file could help us tracking down the problem,
so if you have the time please turn on detailed logging
(http://wiki.netbeans.org/FaqRubyNBLogging), reproduce the issue and
send the log file to me. The root cause here seems to be something else
than in the other thread.

Thanks,
Erno


Lars Frantzen wrote:
Quote:
Hi,

I could fix it by manually adding the JRuby 1.2.0 platform. Something
seems to go wrong when doing the autodetect.

Cheers,
Lars

Erno Mononen wrote:

Lars Frantzen wrote:

Quote:
Hi Erno,

thanks for the reply.

Erno Mononen wrote:

Quote:
Can you try whether the following works from the command line:

<jruby-1.2.0 install dir>bin/jruby -v

yes, it is installed in /usr/local/jruby-1.2.0/ and there is a symlink
to the jruby executable in /usr/local/bin.

I get:

jruby -v
jruby 1.2.0 (ruby 1.8.6 patchlevel 287) (2009-03-16 rev 9419) [amd64-java]

Cheers,
Lars


Quote:
Erno



Lars Frantzen wrote:

Quote:
Hello,

I installed JRuby on my Ubuntu laptop and used the 'Autodetect
Platforms' feature of NetBeans to detect it, which seemed to work fine.

But when I try to run a JRuby project I get:

Exception in thread "main" java.lang.NoClassDefFoundError: org/jruby/Main
Caused by: java.lang.ClassNotFoundException: org.jruby.Main
...

Would be happy for every hint!

Cheers,
Lars
























Back to top
eradikat



Joined: 14 Nov 2009
Posts: 2

PostPosted: Sat Nov 14, 2009 8:48 am    Post subject: I still see this issue with Netbeans 6.7 and JRuby 1.2.0/1.3.1 Reply with quote

Hey guys,

I'm still consistently seeing this issue. Adding the platform manually used to work in previous versions, but now i still see the issue no matter what combination of adding, autodetecting, removing, and adding I do.

I turned on detail logging and here is my IDE Log:

http://pastie.org/private/5ocanyzds9fjpwz5d2v3w

Please advise on how I can resolve this.

It's been plaguing me for months now, and suddenly RubyMine is looking more attractive than NetBeans to my office peers (due to this issue). Not being able to migrate / rake / generate stuff in the IDE is a tough problem to swallow.

EDIT: I should also point out this happens for both Netbeans 6.7 and 6.8 Beta, as well as for JRuby 1.2.0 and 1.3.1
Back to top
View user's profile Send private message
fabsn



Joined: 15 Dec 2009
Posts: 1

PostPosted: Tue Dec 15, 2009 1:35 pm    Post subject: Reply with quote

I had the same issue today with the new version of NetBeans 6.8. I got it solved by adding the /opt/local/share/java/jruby/lib/jruby.jar jar in the java Categori of the project Preference Panel. I think it should be seen as a workarround.
Back to top
View user's profile Send private message
eradikat



Joined: 14 Nov 2009
Posts: 2

PostPosted: Tue Dec 15, 2009 10:45 pm    Post subject: Another workaround Reply with quote

I actually finally figured out the issue yesterday. The way I got it to work was by doing two things:

1) Remove all the ruby platforms it has automatically added. Then, select your JRuby platform manually, but do NOT select the path /usr/local/jruby... you must select the actual source path e.g. /usr/local/src/jruby/1.3.1/bin/jruby. Only then will it work.

2) Add your gems path manually, in my case it's ~/.gems/

Now everything works! Running migrations, generates, rakes and specs all work great.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    NetBeans Forums -> Ruby Users All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB