Issue1135

classification
Title: jython_installer-2.5a3.jar hangs
Type: crash Severity: normal
Components: Installer Versions: 2.5alpha1
Milestone:
process
Status: closed Resolution: works for me
Dependencies: Superseder:
Assigned To: otmarhumbel Nosy List: amak, catherinedevlin, otmarhumbel
Priority: normal Keywords:

Created on 2008-09-22.18:30:37 by catherinedevlin, last changed 2012-03-22.21:26:33 by otmarhumbel.

Files
File name Uploaded Description Edit Remove
jython-installation-autotests.log otmarhumbel, 2008-09-24.06:02:02 A sample installer autotest log on ubuntu
Messages
msg3611 (view) Author: Catherine Devlin (catherinedevlin) Date: 2008-09-22.18:34:39
platform is 
catherine@dellzilla:~/downloads$ java -version
java version "1.5.0"
gij (GNU libgcj) version 4.2.3 (Ubuntu 4.2.3-2ubuntu6)

OS is Kubuntu 8.04 with KDE 4.03

Running
java -jar jython_installer-2.5a3.jar
brings up the "Jython installation" / Language Selection window; its
maximize and minimize buttons are active.  No other buttons (Next or
Close) have any effect.  The window is not repainted after being
partially covered.  Hangs indefinitely.
msg3615 (view) Author: Oti Humbel (otmarhumbel) Date: 2008-09-23.20:16:08
I recommend to install a Sun JDK in any case.

If you want to investigate gij further, you could do
  java -jar jython_installer-25.a3.jar --help
and then try console or silent installation.

Maybe I can get hands on a ubuntu gij, too.
My personal experience with the last gij version were not encouraging: 
even the simplest JUnit tests for the installer failed.
msg3616 (view) Author: Oti Humbel (otmarhumbel) Date: 2008-09-24.06:02:02
The attached log file proves that installation on ubuntu is possible
using Sun JDK 1.6.0_04
msg3617 (view) Author: Oti Humbel (otmarhumbel) Date: 2008-09-24.09:36:40
using gij on Gnome:

huo@bisonws0135:~/temp$ java -version
java version "1.5.0"
gij (GNU libgcj) version 4.2.3 (Ubuntu 4.2.3-2ubuntu6)

Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is
NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE.

The installer switches to headless mode:

huo@bisonws0135:~/temp$ gij -jar jython_installer-2.5a3.jar
Welcome to Jython !
You are about to install Jython version 2.5a3
(at any time, answer c to cancel the installation)
For the installation process, the following languages are available:
English, German
Please select your language [e/g] >>> e
Do you want to read the license agreement now ? [y/n] >>> n
Do you accept the license agreement ? [y/n] >>> y
The following installation types are available:
  1. All (everything, including sources)
  2. Standard (core, library modules, demos and examples, documentation)
  3. Minimum (core)
  9. Standalone (a single, executable .jar)
Please select the installation type [1/2/3/9] >>> 1
Do you want to exclude parts from the installation ? [y/n] >>> n
Please enter the target directory >>> /home/huo/bin/jython-2.5a3
Unable to find directory /home/huo/bin/jython-2.5a3, create it ? [y/n] >>> y
Please enter the target java home directory (== for current) >>> ==
/usr/lib/jvm/java-1.5.0-gcj-4.2-1.5.0.0/jre not found. 
Please enter the target java home directory (== for current) >>> c
Installation cancelled.
huo@bisonws0135:~/temp$ 

But then gij returns a non existing java.home:

huo@bisonws0135:~/bin/jython-2.2.1$ java -jar jython.jar
Jython 2.2.1 on java1.5.0
Type "copyright", "credits" or "license" for more information.
>>> from java.lang import System
>>> from java.io import File
>>> javahome = File(System.getProperty("java.home"))
>>> javahome
/usr/lib/jvm/java-1.5.0-gcj-4.2-1.5.0.0/jre
>>> javahome.exists()
0
>>> 

This could be related to:
https://bugs.launchpad.net/ubuntu/+source/java-common/+bug/45348

I'll check if the installer could fallback to plain 'java' if the
java.home provided by gij does not exist.
msg3618 (view) Author: Oti Humbel (otmarhumbel) Date: 2008-09-24.09:52:37
Sadly I cannot reproduce your GUI case on Gtk:

>>> System.getProperty("java.awt.headless")
>>> from java.awt import GraphicsEnvironment
>>> GraphicsEnvironment.isHeadless()
0
>>> GraphicsEnvironment.getLocalGraphicsEnvironment()
Traceback (innermost last):
  File "<console>", line 1, in ?
   at java.awt.Toolkit.getDefaultToolkit(libgcj.so.81)
   at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(libgcj.so.81)
   at java.lang.reflect.Method.invoke(libgcj.so.81)

java.awt.AWTError: java.awt.AWTError: Cannot load AWT toolkit:
gnu.java.awt.peer.gtk.GtkToolkit
>>> 

(that is the reason the installer switches to console mode)

Maybe you have some console output?
msg3620 (view) Author: Catherine Devlin (catherinedevlin) Date: 2008-09-24.13:15:05
You're right, it works fine with Sun Java.  I keep forgetting that the
java that comes with Ubuntu is jig.  And yes, maybe the problem is
KDE-only, or even KDE4-only.

I got no console output.

If you like, I could create a VirtualBox virtual machine with gij and
Kubuntu-KDE4 and ship it up to you.

Maybe a good alternative would just be to insert a check for Java
version that throws an explicit warning if it's gij?

Thanks!
msg3623 (view) Author: Oti Humbel (otmarhumbel) Date: 2008-09-25.11:50:10
Catherine,

it would be great if I could reproduce the effect.
So if it's not too difficult, please put together a VirtualBox.

I do not want to a priori ban other open source developers, so I'll put
some effort into enabling installation under GNU java (in a limited way,
if necesesary).

Thanks a lot!
Oti.
msg3629 (view) Author: Oti Humbel (otmarhumbel) Date: 2008-10-01.06:39:17
Dani Kirchhofer (kid) set up a kubuntu machine for me:

id@kid-laptop:~$ java -version
java version "1.5.0"
gij (GNU libgcj) version 4.2.3 (Ubuntu 4.2.3-2ubuntu6)

Even there the installer switched to console mode.
So my decision is to generally disable gui installation on gnu java.
msg3630 (view) Author: Oti Humbel (otmarhumbel) Date: 2008-10-01.06:41:12
The tests on kubuntu revealed another bug in the installer:
The -v/--verbose option disables autoswitching to console mode.
Thanks kid for opening my eyes!
msg3638 (view) Author: Oti Humbel (otmarhumbel) Date: 2008-10-03.07:45:26
Summary:
1. Fix the -v bug
2. Auto-switch to headless mode on GNU java
3. Work around the GNU java.home problem
msg3640 (view) Author: Catherine Devlin (catherinedevlin) Date: 2008-10-03.11:09:52
I'm sorry, your message about a VirtualBox got buried in my email -
thanks to Dani for making one!
msg6877 (view) Author: Alan Kennedy (amak) Date: 2012-03-19.20:55:53
Is this issue still happening?

Can it be resolved?
msg6953 (view) Author: Oti Humbel (otmarhumbel) Date: 2012-03-22.06:41:19
The -v not autoswitching to console mode is resolved:


ohumbel@ubuntu:~/Downloads$ java -version
java version "1.6.0_20"
OpenJDK Runtime Environment (IcedTea6 1.9.13) (6b20-1.9.13-0ubuntu1~10.04.1)
OpenJDK Client VM (build 19.0-b09, mixed mode, sharing)

ohumbel@ubuntu:~/Downloads$ java -jar jython_installer-2.5.3b1.jar -v
system properties dumped to /tmp/System1021927178363866272.properties
reading jar info
checking gui availability
java.awt.headless is true
auto-switching to console mode
using the console installer
Welcome to Jython !
You are about to install Jython version 2.5.3b1
(at any time, answer c to cancel the installation)
For the installation process, the following languages are available: English, German
Please select your language [E/g] >>>
msg6954 (view) Author: Oti Humbel (otmarhumbel) Date: 2012-03-22.06:52:21
I'll try if i can switch to gnu java and test again with python 2.5.3b1
msg6956 (view) Author: Oti Humbel (otmarhumbel) Date: 2012-03-22.21:26:33
Now that we have OpenJDK everywhere, there is no need to hunt for GNU Java, IMHO.

ohumbel@ubuntu:~$ sudo update-alternatives --config java
[sudo] password for ohumbel: 
There is only one alternative in link group java: /usr/lib/jvm/java-6-openjdk/jre/bin/java
Nothing to configure.
History
Date User Action Args
2012-03-22 21:26:33otmarhumbelsetstatus: open -> closed
resolution: works for me
messages: + msg6956
2012-03-22 06:52:22otmarhumbelsetmessages: + msg6954
2012-03-22 06:41:20otmarhumbelsetmessages: + msg6953
2012-03-19 20:55:53amaksetnosy: + amak
messages: + msg6877
2008-12-17 19:57:33fwierzbickisetpriority: normal
2008-10-03 11:09:52catherinedevlinsetmessages: + msg3640
2008-10-03 07:45:26otmarhumbelsetmessages: + msg3638
2008-10-01 06:41:12otmarhumbelsetmessages: + msg3630
2008-10-01 06:39:17otmarhumbelsetmessages: + msg3629
2008-09-25 11:50:11otmarhumbelsetmessages: + msg3623
2008-09-24 13:15:05catherinedevlinsetmessages: + msg3620
2008-09-24 09:52:38otmarhumbelsetmessages: + msg3618
2008-09-24 09:36:41otmarhumbelsetmessages: + msg3617
2008-09-24 06:02:03otmarhumbelsetfiles: + jython-installation-autotests.log
messages: + msg3616
2008-09-23 20:16:09otmarhumbelsetassignee: otmarhumbel
messages: + msg3615
nosy: + otmarhumbel
2008-09-22 18:34:39catherinedevlinsetmessages: + msg3611
2008-09-22 18:30:37catherinedevlincreate