FAQ
Cover
This is the archive Discourse for the Processing (ALPHA) software.
Please visit the new Processing forum for current information.

   Processing 1.0 _ALPHA_
   Bugs
   Bug Fixes, Implemented Suggestions
(Moderator: fry)
   java mode or external class "hangs" sketch
« Previous topic | Next topic »

Pages: 1 
   Author  Topic: java mode or external class "hangs" sketch  (Read 547 times)
amoeba

WWW
java mode or external class "hangs" sketch
« on: Oct 26th, 2003, 7:35pm »

[bug as seen in Processing 0065]
 
Sketches hang when I try to use Java mode or load external classes. The IDE is unaffected, but sketches stop executing without reporting any errors. It has showed up before when I tried to do a simple Java mode example, and now when I tried to experiment with Pitaru's sonia lib.
 
From using println to give debug messages, I've figured out that setup() runs, then loop() runs once or twice before hanging. The window comes up correctly, but does not update. If I press stop the window will sometimes display the drawn frame correctly.
 
When using println to debug I sometimes get the following error:
 
Code:

PdeMessageSiphon err java.lang.NullPointerException
java.lang.NullPointerException
      at PdeRuntime.message(PdeRuntime.java:459)
      at PdeMessageSiphon.run(PdeMessageSiphon.java:55)
      at java.lang.Thread.run(Thread.java:536)

 
 
This is when executing the following program:
 
Code:

public class MyDemo extends BApplet {  
  void setup()  
  {  
    size(200, 200);  
    background(255);  
    rectMode(CENTER_DIAMETER);  
    noStroke();  
    fill(255, 204, 0);  
    println("setup");
  }  
 
  void loop()  
  {  
    println("loop");
    background(255);  
    rect(width-mouseX, height-mouseY, 50, 50);  
    rect(mouseX, mouseY, 50, 50);  
  }  
}  

 
I was thinking I'd be patient and wait for Java mode to become more stable in future releases, but sound input is too tempting...
 
 
m
« Last Edit: Oct 26th, 2003, 7:54pm by amoeba »  

marius watz // amoeba
http://processing.unlekker.net/
fry


WWW
Re: java mode or external class "hangs" sketch
« Reply #1 on: Oct 27th, 2003, 2:35am »

ahhhhh...
 
good catch. that's a really nasty one, actually. all the System.out messages (like println) were getting sent to System.err, so p5 thought that your "loop" messages were a long stack trace for an exception..  
 
the happy ending is that it's all fixed for 67.
 
amit was running into something similar, but i was confused about what was going on.  
 
i'm glad you opted to report this one, otherwise you'd have been waiting a long time for java mode to get better and i wouldn't have had a clue that this was even broken as badly as it was
 
amoeba

WWW
Re: java mode or external class "hangs" sketch
« Reply #2 on: Oct 27th, 2003, 11:44pm »

de rien, baby. can't wait for 0067.
 
m
 

marius watz // amoeba
http://processing.unlekker.net/
trip

triparepa WWW Email
Re: java mode or external class "hangs" sketch
« Reply #3 on: Oct 29th, 2003, 7:56am »

I'm running 0067, and it still "hangs" with the above code. Exactly like 65.
 
No more PdeMessageSiphon err though.
 
If I remove all the println()'s though, it hangs pretty much like 65, no messages, just a non working window.
 
c
 
mKoser

WWW Email
Re: java mode or external class "hangs" sketch
« Reply #4 on: Oct 29th, 2003, 10:19am »

i just gave it a go (winXP, 0067.expert) and it worked just fine!
 
trip, I am wondering if you might have "the first" verion of 0067, the one that was build on the old code...
 
see fry's post here:
http://proce55ing.net/discourse/yabb/board_Proce55ing_software__bugs_action_display_num_1067360602.html
 
and what system are you running
 
+ mikkel
« Last Edit: Oct 29th, 2003, 10:20am by mKoser »  

mikkel crone koser | www.beyondthree.com | http://processing.beyondthree.com
trip

triparepa WWW Email
Re: java mode or external class "hangs" sketch
« Reply #5 on: Oct 31st, 2003, 2:14am »

I just redownloaded 67 and java mode still hangs the sketch. I am using the code that was mentioned above.. and I'm in winXP
 
c
 
Pages: 1 

« Previous topic | Next topic »