B4J Question [ABMATERIAL] Webapp runs on Windows 8.1 but not on Raspbian nor ubuntu 16.0

inakigarm

Well-Known Member
Licensed User
Longtime User
Hi:

I've spent last day trying to find where's the error; the webapp (a modified version of ABMaterial Feedback runs fine on Windows 8.1 but can't get working on Raspi (Raspbian nor Ubuntu 16.0). Edit: B4J 5.90, jserver 2.80 and ABMaterial 3.50

The error is the following: (line 360 corresponds to page.Refresh command)

Ha ocurrido un error en la línea: 360 (OverviewCasesPage)
java.lang.NullPointerException
at com.ab.abmaterial.ABMTable.GetSortColumn(Unknown Source)
at com.ab.abmaterial.ABMTable.RefreshInternal(Unknown Source)
at com.ab.abmaterial.ABMTable.FirstRunInternal(Unknown Source)
at com.ab.abmaterial.ABMCell.RefreshInternalExtra(Unknown Source)
at com.ab.abmaterial.ABMRow.RefreshInternal(Unknown Source)
at com.ab.abmaterial.ABMPage.Refresh(Unknown Source)
at com.abmaterial.b4xgoodies.overviewcasespage._websocket_connected(overviewcasespage.java:3165)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:613)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:231)
at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:159)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:90)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:93)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:77)
at anywheresoftware.b4j.object.WebSocketModule$Adapter$ThreadHandler.run(WebSocketModule.java:188)
at anywheresoftware.b4a.keywords.SimpleMessageLoop.runMessageLoop(SimpleMessageLoop.java:30)
at anywheresoftware.b4a.StandardBA.startMessageLoop(StandardBA.java:26)
at anywheresoftware.b4a.ShellBA.startMessageLoop(ShellBA.java:114)
at anywheresoftware.b4a.keywords.Common.StartMessageLoop(Common.java:148)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:303)
at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:159)
at sun.reflect.NativeMethod
AccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:90)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:93)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:77)
at anywheresoftware.b4j.object.JServlet.createInstance(JServlet.java:65)
at anywheresoftware.b4j.object.BackgroundWorkersManager$1.run(BackgroundWorkersManager.java:21)
at anywheresoftware.b4a.keywords.SimpleMessageLoop.runMessageLoop(SimpleMessageLoop.java:30)
at anywheresoftware.b4a.StandardBA.startMessageLoop(StandardBA.java:26)
at anywheresoftware.b4a.ShellBA.startMessageLoop(ShellBA.java:114)
at anywheresoftware.b4a.keywords.Common.StartMessageLoop(Common.java:148)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:303)
at anywheresoftware.b4a.shell.Shell.raiseEvent(S
hell.java:159)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:90)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:93)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:77)
at anywheresoftware.b4j.object.JServlet.createInstance(JServlet.java:65)
at anywheresoftware.b4j.object.BackgroundWorkersManager$1.run(BackgroundWorkersManager.java:21)
at anywheresoftware.b4a.keywords.SimpleMessageLoop.runMessageLoop(SimpleMessageLoop.java:30)
at anywheresoftware.b4a.StandardBA.startMessageLoop(StandardBA.java:26)
at anywheresoftware.b4a.ShellBA.startMessageLoop(ShellBA.java:114)
at anywheresoftware.b4a.keywords.Common.StartMessageLoop(Common.java:148)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:303)
at an
ywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:159)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:90)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:93)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:77)
at com.abmaterial.b4xgoodies.main.main(main.java:29)

This is the link to the Webapp (with all components & db); can anyone test it or have any clue about this behavior?

Thanks
 
Last edited:

inakigarm

Well-Known Member
Licensed User
Longtime User
Thanks @Cableguy ; off course I've tried, this search and many others. Searched also on Feedback database.

The Webapp includes 4 pages: in Rpi and AWS - Ubuntu, all pages works fine except the Page that includes an ABMTable component; in Windows 8.1, all pages run fine.

Edit:
the www folder is the same on both systems
 
Upvote 0

Cableguy

Expert
Licensed User
Longtime User
do you also have all the php/javascript/etc interpreters installed?
The RPi is a simplified system, and so it may lack a few "basic" features that prevent it from running as it should.
Thanks @Cableguy ; off course I've tried, this search and many others. Searched also on Feedback database.
I didn't mean any disrespect, obviously
 
Upvote 0

inakigarm

Well-Known Member
Licensed User
Longtime User
Have you also copied the 'copymewithjar.needs' file next to your .jar file on the rPi?
Yes, but everytime I run the jar in RPI environment (after copying the correct jar and copymewithjar.needs to its corresponding folder on home/pi) the copymewithjar file modifies its content to
B4X:
ABMCacheSystem:1.0
Obviously, this doesn't let the pages to load the components correctly.
Copying exactly the jar and copymewithjar.needs to AWS Ubuntu it runs fine (because the copymewithjar.needs doesn't change his content)


Edit: I've found the error on RPI, maybe a bug @alwaysbusy ?
On home/pi I've a source B4J file code (AlarmControlnonUI.b4j) ; when running the jar on RPI on home/pi/ABMB4xgoodies folder, it creates a strange B4JAnalyse.log (attached) and this modifies also the copymewithjar.needs contents to ABMCacheSystem:1.0

Strange, isn't it?

I supose that anything in the jar tries to buid the B4JAnalyse when searching for sources (b4J). It makes sense for you ?

After all (and many hours), the app runs fine on RPI/AWS !!
 

Attachments

  • B4JAnalyse_badlog.txt
    21.1 KB · Views: 183
Upvote 0

alwaysbusy

Expert
Licensed User
Longtime User
it creates a strange B4JAnalyse.log (attached) and this modifies also the copymewithjar.needs
The only reason this should happen is because the .jar was running in debug mode. The ABMaterial library does act differently when if debug or release mode. In debug mode it collects a lot of info from the .bas files and writes its findings in the .needs file. In release mode, it does not have the source code, so it relies on the info of the .needs file.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…