Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
trinay
Visitor

Creating bright script project in eclipse 3.7.2 throws error

hi,

I have installed the brightscript plugin in eclipse 3.7.2 .when i create new bright script project.I got the below errors

Errors occurred during the build.
Errors running builder 'Script Builder' on project 'sample'.
java.lang.NullPointerException

How to fix the above error.

Thanks
0 Kudos
5 REPLIES 5
malloys
Visitor

Re: Creating bright script project in eclipse 3.7.2 throws e

"trinay" wrote:
hi,

I have installed the brightscript plugin in eclipse 3.7.2 .when i create new bright script project.I got the below errors

Errors occurred during the build.
Errors running builder 'Script Builder' on project 'sample'.
java.lang.NullPointerException

How to fix the above error.

Thanks


Although you haven't yet provided enough info for me to be sure, for now I'm going to assume the problem is the memory management issue others have had in the past couple of months.
Recent releases of the plugin require more memory than previous versions due to the type inference system ( which provides auto-completion, hover-help, type checking, and other significant benefits ).

The source of the issue you are seeing is usually a combination of one or more of the following things in rank order:

1) Your eclipse instance is running a version of java that's older than 1.7 ( older java versions in the 1.5 and 1.6 range have a known bug involving memory management, and some of the older,early 1.7 releases also have this bug ). Updating to the latest version of Java may clear up the error, or at least cause the real underlying error to be displayed ( out-of-memory ).

2) You are running a 64-bit version of eclipse ( which has a higher memory overhead than 32-bit eclipse, and generally does not provide any advantages over the 32-bit version except being able to address memory over 4GB... the latter, btw, is why most web browsers are still 32-bit apps even for the 64-bit operating systems). Switching from a 64-bit version of eclipse to a 32-bit version will decrease the amount of memory overhead needed, and may be enough to help you avoid the out-of-memory condition.

3) You haven't increased your max heap memory setting for your instance of eclipse to the level needed to accommodate your open projects ( eclipse ships with a low default max heap setting in the eclipse.ini file ). The default value is 384m, but I've found I need 1024m for most projects now. The max heap setting is "-Xmx" in your eclipse.ini file ( same directory as your eclipse executable ) is usually found at the bottom of the file.

4) You have limited available physical memory and/or other running processes that are consuming a significant percentage of your memory ( YMMV ).


So, the questions are:

a) what version of java is your eclipse instance running?

b) Are you running a 32-bit or 64-bit version of eclipse?

c) What is your eclipse max heap size ( in eclipse.ini )?

d) Have you closed all unnecessary apps ( and other eclipse projects not required by your current BrightScript project )?

I can easily determine the answer to (a),(b), and (c) for you if you PM me your eclipse configuration, which is gettable in eclipse by: Help->About Eclipse->Installation Details->Configuration

Cheers
0 Kudos
trinay
Visitor

Re: Creating bright script project in eclipse 3.7.2 throws e

hi malloys,

Thank you.I have solved the issue by upgrading the latest java version and increasing the memory 1024 m in eclipse.ini.

Now using Eclipse version :: 3.6.1 .If i run the bright script project.It shows "The selection cannot be launched and there are no recent launches".

How to run the bright script project.

Thanks
0 Kudos
malloys
Visitor

Re: Creating bright script project in eclipse 3.7.2 throws e

"trinay" wrote:
hi malloys,

Thank you.I have solved the issue by upgrading the latest java version and increasing the memory 1024 m in eclipse.ini.

Now using Eclipse version :: 3.6.1 .If i run the bright script project.It shows "The selection cannot be launched and there are no recent launches".

How to run the bright script project.

Thanks


Since there is no Roku emulator, BrightScript projects cannot be run directly from the local eclipse environment ( which is what you apparently tried to do ).
As a corollary, debugging a BrightScript project is also not done locally via the usual local eclipse launching.

However, from eclipse you can cause your BrightScript project to be uploaded (aka exporting) to one of your Roku boxes, which automatically launches it on that box. Once launched, you can then optionally debug the project remotely via a Roku console connection.

To get you started, both exporting and the debug console are mentioned in section 2 of the Eclipse plugin guide: http://sdkdocs.roku.com/display/sdkdoc/Eclipse+Plugin+Guide

Cheers
0 Kudos
trinay
Visitor

Re: Creating bright script project in eclipse 3.7.2 throws e

Thanks malloys for your information.I have followed the steps in eclipse plugin guide.I have the Ip address of the roku box.
If i use that ip ,it shows the below error

Unable to get current deployment values from roku box at ip address

Reason :
java.net.SocketTimeoutException:Read Timed out

at java.net.SocketInputStream.socketRead0(Native Method)

at java.net.SocketInputStream.read(Unknown Source)

thanks
0 Kudos
malloys
Visitor

Re: Creating bright script project in eclipse 3.7.2 throws e

"trinay" wrote:
Thanks malloys for your information.I have followed the steps in eclipse plugin guide.I have the Ip address of the roku box.
If i use that ip ,it shows the below error

Unable to get current deployment values from roku box at ip address

Reason :
java.net.SocketTimeoutException:Read Timed out

at java.net.SocketInputStream.socketRead0(Native Method)

at java.net.SocketInputStream.read(Unknown Source)

thanks


A socket timeout means eclipse can't connect to the Roku box you specified.

This can be caused by 1 or more of:

1) You have not yet enabled developer mode ( See http://sdkdocs.roku.com/display/sdkdoc/Developer+Guide#DeveloperGuide-71EnablingDevelopmentModeonyou... )
2) The box IP address you entered is not correct.
3) The box lost it's connection to the network, but it hasn't detected and displayed this to you yet.
4) The box's firmware version is the limited release 5.2 beta ( which is not supported by the current plugin - firmware 5.2 has a new dev mode security feature that trips up the currently released plugin. Support for 5.2 is currently under development ). It's not very likely to be this one unless someone at Roku has explicitly told you they added you to the beta group.

Cheers
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.