Bug 152460 - IOException: Fail to add built-in jython as new Python Platform
IOException: Fail to add built-in jython as new Python Platform
Status: VERIFIED FIXED
Product: python
Classification: Unclassified
Component: Projects
6.x
All All
: P1 (vote)
: TBD
Assigned To: ardavis26
nbpythonqa
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-11-05 21:40 UTC by _ hong_lin
Modified: 2009-01-15 01:59 UTC (History)
0 users

See Also:
Issue Type: DEFECT
:


Attachments
Screen shot, missing jython platform (77.49 KB, image/png)
2008-11-05 21:42 UTC, _ hong_lin
Details
log file (50.67 KB, text/plain)
2008-11-05 21:43 UTC, _ hong_lin
Details
exception when add jython.bat (36.29 KB, text/plain)
2008-11-05 22:56 UTC, _ hong_lin
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ hong_lin 2008-11-05 21:40:40 UTC
Product Version: NetBeans IDE 6.5 (Build 20081105122310) -- Continues build #153
Java: 1.6.0_07; Java HotSpot(TM) Client VM 10.0-b23
System: Windows Vista version 6.0 running on x86; Cp1252; en_US (nb)

Steps to reproduce it:
1. Start the IDE with a clean userdir.
2. Select File -> New Project in the main menu. 
3. Select Python -- Python project. Click Next. The "New Python Project" panel comes up. The "Python Platform" field is
empty: <Valid platform has to be selected>. I was told that jython should be the default platform (See attached
screenshot MissingJpythonPlatform.png).
4. Click "Manage..." button. 
5. Click "New" to add new platform: Select the built-in jython (located at <netbeans>/python1/jpython-2.5/jython.jar),
and click "Open".
  ==> Nothing happened. The following exception and ExecutionException can be found in messages.log file (attached)
java.io.IOException: CreateProcess error=193, %1 is not a valid Win32 application
	at java.lang.ProcessImpl.create(Native Method)
	at java.lang.ProcessImpl.<init>(Unknown Source)
	at java.lang.ProcessImpl.start(Unknown Source)
Caused: java.io.IOException: Cannot run program "C:\Users\Hong\Contacts\Hong.contact" (in directory
"C:\Users\Hong\Downloads\netbeans-hudson-python-153-python\netbeans\python1"): CreateProcess error=193, %1 is not a
valid Win32 application
	at java.lang.ProcessBuilder.start(Unknown Source)
	at org.netbeans.modules.extexecution.api.ExternalProcessBuilder.call(ExternalProcessBuilder.java:263)
	at org.netbeans.modules.extexecution.api.ExternalProcessBuilder.call(ExternalProcessBuilder.java:65)
[catch] at org.netbeans.modules.extexecution.api.ExecutionService$3.call(ExecutionService.java:250)
	at org.netbeans.modules.extexecution.api.ExecutionService$3.call(ExecutionService.java:227)
	at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
	at java.util.concurrent.FutureTask.run(Unknown Source)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)
Comment 1 _ hong_lin 2008-11-05 21:42:32 UTC
Created attachment 73327 [details]
Screen shot, missing jython platform
Comment 2 _ hong_lin 2008-11-05 21:43:26 UTC
Created attachment 73328 [details]
log file
Comment 3 ardavis26 2008-11-05 22:35:15 UTC
You are not supposed to select the jar file you are supposed to select the bat file in the bin directory (bin/jython.bat)
Comment 4 _ hong_lin 2008-11-05 22:54:42 UTC
Sorry for giving the wrong steps.

But I still couldn't add the jython platform, even thought I tried to add the right file:
<netbeans>/python1/jpython-2.5/bin/jython.bat

This time, I receive a new PythonException, detail can be found in the attached messages-bat.log file, it is also not
exactly like the exception in issue 152377:
org.netbeans.modules.python.api.PythonException: Could not discover Python properties
[catch] at org.netbeans.modules.python.api.PythonPlatformManager.findPlatformProperties(PythonPlatformManager.java:241)
	at org.netbeans.modules.python.platform.panels.PythonPlatformPanel.newPlatformActionPerformed(PythonPlatformPanel.java:423)
	at org.netbeans.modules.python.platform.panels.PythonPlatformPanel.access$100(PythonPlatformPanel.java:33)
	at org.netbeans.modules.python.platform.panels.PythonPlatformPanel$2.actionPerformed(PythonPlatformPanel.java:112)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
......
Comment 5 _ hong_lin 2008-11-05 22:56:10 UTC
Created attachment 73332 [details]
exception when add jython.bat
Comment 6 ardavis26 2008-11-05 23:06:04 UTC
Added exec filter on File Chooser to get rid of this problem 
Comment 7 ardavis26 2008-11-05 23:10:31 UTC
can you open a dos propmt and navigate to the jython directory and run jython from the command line
Comment 8 ardavis26 2008-11-06 17:01:53 UTC
I have tested this twice on a windows xp box and I still don't see it.  my linux box does not have this issue either.
Try the latest build 157 and see if it goes away. 
Comment 9 _ hong_lin 2008-11-07 01:17:15 UTC
It is fixed in the latest build #160. :)
Comment 10 _ hong_lin 2008-11-07 01:18:36 UTC
Verified the fix in build #160. But the latest installer build still has the problem.


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo