This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 149162

Summary: Blank Midlet OTA Provisioning crashes
Product: javame Reporter: bht <bht>
Component: Build SystemAssignee: Petr Suchomel <psuchomel>
Status: RESOLVED WONTFIX    
Severity: blocker CC: ca-nb
Priority: P1 Keywords: RELNOTE
Version: 6.x   
Hardware: All   
OS: Windows ME/2000   
Issue Type: DEFECT Exception Reporter:

Description bht 2008-10-04 23:23:29 UTC
The most basic midlet possible cannot be run OTA within the emulator.

I come across this when I try to get rid of the warning when I write a testcase for another issue where the push
registry is involved.

I don't really need to run OTA because I use push registration dynamically via the API, not via application descriptor
files.

But for the other testcase I need to run OTA otherwise it would not be clean if I send a testcase that has an obvious
warning in it, i.e. "Warning: could not write push registration file: NULL filename" and "Please try and run the MIDlet
via OTA."

How to reproduce:

Create a new project:
File -> New Project -> Java ME -> Mobile Application
Click Finish
In Project Properties, select Build -> Running
Check the radio button "Execute through OTA(Over The Air Provisioning)"

Then run the project.

On my computer, the phone emulator pops up twice, but then closes with the error:

build-impl.xml:997: Execution failed with error code -1.
Comment 1 Petr Suchomel 2008-10-06 08:13:33 UTC
Do you have any test case project? Have you tried to deploy through OTA outside of NetBeans just using emulator? It is
very hard to say, what can be a root cause of problem.
Comment 2 bht 2008-10-06 10:06:50 UTC
It should be very easy to reproduce the crash if you follow the step by step instructions.

The testcase, which is the basic Hello World Midlet, is included in Netbeans itself as a template.

No, I have not tried the WTK without NetBeans, and I don't think I can make any plans for that.

The interesting thing is that there is no visible meaningful diagnostics in the crash. It would be good to have that.
Comment 3 Petr Suchomel 2008-10-06 10:18:29 UTC
The problem is, if I try to run using these steps all is running fine. Can some firewall be involved - we had some issue
reports which included some firewall blocking?
Comment 4 Andrei Chistiakov 2008-10-06 18:34:20 UTC
Additional steps to reproduce the issue:
- follow the steps mentioned above;
- do not exit the MIDlet;
- close IDE;
- wait unitl the emulator is closed;
- restart IDE;
- run the MIDlet.

After that, the storage root remains locked.

To recover from this situation:
- before restart, go to %USERPROFILE%\j2mewtk\2.5.2\appdb\DefaultColorPhone and delete file 'in.use'.

bth,
please try to delete file 'in.use' if the one exists. Also please let us know if this helps. Thank you!
Comment 5 bht 2008-10-07 08:14:18 UTC
I closed the IDE (the midlet was not running because it had crashed)
Then I deleted the file in.use. The file modification date was the current date from the crash a few minutes earlier.

I expected it to be old, from the crash a few days earlier.

Then I re-started the IDE and re-ran the project.

Runs fine. The midlet starts on the second attempt. I had tried this on a different computer with the same IDE version,
but Windows XP. There, the midlet starts ok the same way, on the second attempt. So all seems to be fine now.

Could you get the computer to give a warning so others can find the file and delete it when necessary?

I know what to do now so I am ok. Many thanks.
Comment 6 Petr Suchomel 2008-10-07 09:03:34 UTC
This is WTK issue, we are not able to fix this one. Should be in RELEASE NOTES, added keyword. Thanks for valuable
evaluation
Comment 7 Bradley Schmidt 2008-10-27 14:46:40 UTC
Since the impact of this issue is rather limited, I propose making it an FAQ where it will have better visibility to
users. Please see http://wiki.netbeans.org/ReleaseNoteGuidelines for additional reasons.