Closed GoogleCodeExporter closed 9 years ago
I am unable to reproduce the problem with the latest build... Whenever I try
to call that payload method with an empty devices list, I get
"java.lang.ArithmeticException: / by zero", which seems appropriate.
Could you please try again with the latest build from the trunk?
If the issue still occurs, please provide a working sample code (the code you
provided doesn't compile because of the invalid new List() construction, so I
am assuming this is not the exact code you used), and include a stack trace
dump when the code hangs.
Thank you!
Original comment by sype...@gmail.com
on 13 Apr 2012 at 2:17
Sorry, my bad. I'm attaching an example source file and a stack trace dump.
I'll download the latest build from the trunk later and let you know the
results.
Original comment by rcha...@devosinc.com
on 13 Apr 2012 at 11:27
Attachments:
I ran the same sample code with version 2.3 alpha 4 (downloaded from trunk) and
I got an java.lang.ArithmeticException:
java.lang.ArithmeticException: / by zero
at javapns.notification.transmission.NotificationThreads.makeGroups(NotificationThreads.java:214)
at javapns.notification.transmission.NotificationThreads.<init>(NotificationThreads.java:44)
at javapns.Push.payload(Push.java:210)
at com.notificador.SimplePush.main(SimplePush.java:17)
Hope this helps :)
Original comment by rcha...@devosinc.com
on 13 Apr 2012 at 11:49
Since the latest build does throw an exception as expected (does not hang), I'm
lowering the priority on this issue, which I believe turns out to be a request
for throwing a more self-explanatory exception instead of that generic
ArithmeticException :)
Original comment by sype...@gmail.com
on 14 Apr 2012 at 6:08
Requested enhancement included in r363, which nows throws a proper
IllegalArgumentException("Device list is empty, resulting in no threads being
created.").
Original comment by sype...@gmail.com
on 24 Apr 2012 at 3:19
Original issue reported on code.google.com by
rcha...@devosinc.com
on 13 Apr 2012 at 1:30