Title: Import * doesn't work on JDK9
Type: behaviour Severity: normal
Components: Core Versions: Jython 2.7
Milestone: Jython 2.7.2
Status: open Resolution: accepted
Dependencies: Superseder:
Assigned To: Nosy List: alanb, amak, darjus, fwierzbicki, mr, rpan, sfelts, zyasoft
Priority: urgent Keywords:

Created on 2015-05-28.17:56:24 by sfelts, last changed 2017-07-14.06:56:58 by rpan.

msg10089 (view) Author: Stephen Felts (sfelts) Date: 2015-05-28.17:56:23
I had "from import *"
It no longer works.  I needed to replace it with the explicit imports needed.  For example,
msg10090 (view) Author: Jim Baker (zyasoft) Date: 2015-05-28.19:18:04
Java 9 has changed jar formats; I believe this is summarized by This means that our package scanner also needs to change.

We should start testing against Java 9, in prep for its release date in just over 1 year; Sept 22, 2016 was recently announced.

Ideally we can start supporting by2.7.1, but certainly by 2.7.2.
msg10276 (view) Author: Jim Baker (zyasoft) Date: 2015-09-22.18:52:13
This will most likely slip to 2.7.2, to be released in May 2016. I will note that I'm posting this note on Sept 22, 2015, exactly one year in advance of the planned released date for Java 9 :)

For Java 9, one thing I like is that it seems feasible to remove package scanning altogether for Java SE components, given the possibility of module reflection ( This seems at first glance preferable to our current approach of scanning rt.jar and also seems in the spirit of Project Jigsaw as well. We may be able to extend this to arbitrary jars in general, TBD.

It will be easy enough to test out these assumptions in Python code before  attempting changes in import logic.
msg10634 (view) Author: Jim Baker (zyasoft) Date: 2016-01-12.00:42:47
Moving to 2.7.2 - we just don't have time to get such a major change in 2.7.1. In contrast, 2.7.2 lets us get this right.

But it will be a blocker for 2.7.2, so marking urgent as a consequence.
msg10649 (view) Author: Darjus Loktevic (darjus) Date: 2016-01-15.12:16:07
Looks like Java 9 release is slipping by 6mo which means the GA will be 2017/03/23 . In a way, lucky for us this gives us a bit more time work on Java 9 support as we ourselves are slipping with 2.7.1 release of Jython. But this does not change the priority of making sure Java 9 works with Jython 2.7.2
msg10651 (view) Author: Jim Baker (zyasoft) Date: 2016-01-15.15:22:22
Darjus, good to see the alignment in our schedules. As I see it, we should triage this bug as the second most important bug after #2182 in 2.7.2. (Regardless, we would expect work on these two bugs to be done in parallel.)

Also we need to use the jrt filesystem (, which corresponds in any event with the existing package scanner. As far as I can tell, java.lang.reflect.Module and related introspection does not provide sufficient support to get at package hierarchies.
msg11331 (view) Author: Alan Bateman (alanb) Date: 2017-04-28.08:40:39
See also this issue in the OpenJDK JIRA where it initially looked like a startup performance issue in JDK 9:
msg11475 (view) Author: (rpan) Date: 2017-07-14.06:56:58
The OpenJDK bug was closed. Its corresponding Jython issue is:
Date User Action Args
2017-07-14 06:56:58rpansetnosy: + rpan
messages: + msg11475
2017-04-28 08:40:40alanbsetnosy: + alanb
messages: + msg11331
2016-01-15 15:22:22zyasoftsetmessages: + msg10651
2016-01-15 12:16:08darjussetnosy: + darjus
messages: + msg10649
2016-01-12 00:42:47zyasoftsetpriority: high -> urgent
nosy: + fwierzbicki
messages: + msg10634
milestone: Jython 2.7.1 -> Jython 2.7.2
2015-12-30 00:03:53zyasoftsetpriority: normal -> high
2015-12-30 00:00:50zyasoftsetmilestone: Jython 2.7.1
2015-09-22 18:52:14zyasoftsetmessages: + msg10276
2015-09-17 15:38:34mrsetnosy: + mr
2015-06-05 10:11:21amaksetnosy: + amak
2015-05-28 19:18:05zyasoftsetpriority: normal
resolution: accepted
messages: + msg10090
nosy: + zyasoft
2015-05-28 17:56:24sfeltscreate