Issue2121

classification
Title: Jython jar on Maven central embeds other third party libraries
Type: Severity: normal
Components: Versions: Jython 2.7
Milestone: Jython 2.7.2
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: jeff.allen, rjn, tuska, zyasoft
Priority: normal Keywords: gradle, patch

Created on 2014-04-07.15:24:20 by tuska, last changed 2019-11-02.15:41:32 by jeff.allen.

Files
File name Uploaded Description Edit Remove
issue2121.patch rjn, 2017-01-15.23:55:08
Messages
msg8270 (view) Author: Thomas Mortagne (tuska) Date: 2014-04-07.15:24:19
I can understand it for the jython-standalone one but there is no reason to emmbed all that in the jython jar. It generates tons of duplicated classes.

There is also something that looks like empty (except for the package-info.class files) guava embedded.
msg8271 (view) Author: Thomas Mortagne (tuska) Date: 2014-04-07.15:25:20
I'm talking about the 2.7b1 release which is not listed in the "Versions" list so I indicated 2.7.
msg8272 (view) Author: Thomas Mortagne (tuska) Date: 2014-04-07.15:31:29
The main one is xml-apis:xml-apis (probably 1.4.01).
msg8273 (view) Author: Thomas Mortagne (tuska) Date: 2014-04-07.15:48:58
Yes that's the 1.4.01 according to org.apache.xmlcommons.Version class.
msg8274 (view) Author: Jim Baker (zyasoft) Date: 2014-04-07.16:36:27
We would like to make this change, however this requires rethinking our current build process. This will also help in terms of being compatible in the context of Debian packaging.
msg9080 (view) Author: Jim Baker (zyasoft) Date: 2014-10-05.17:12:48
Defer to 2.7.1
msg11022 (view) Author: Rafal Nagrodzki (rjn) Date: 2017-01-15.23:55:08
I prepared a very simple solution which has an obvious downside of dependencies being specified in two places.

I'm happy to hear your comments and give it another try, if you give me some guidance on how you want to manage dependencies ideally.
msg11023 (view) Author: Rafal Nagrodzki (rjn) Date: 2017-01-16.09:44:50
I just realized I did not tackle package name remappings so my patch is incomplete.
msg11302 (view) Author: Jim Baker (zyasoft) Date: 2017-04-12.16:02:59
We plan to address in 2.7.2 - one of the top priorities of that work is to go to a Gradle build and move to a GitHub based workflow.

First, need to get out the long delayed 2.7.1 of course!
msg11303 (view) Author: Rafal Nagrodzki (rjn) Date: 2017-04-12.18:34:15
@zyasoft Thanks for the update.
msg12692 (view) Author: Jeff Allen (jeff.allen) Date: 2019-10-06.10:33:40
There is now a Gradle build, which if we've done it right, provides the "extreme" solution of making all external dependencies ... external.

The traditional approach will continue to be supported, but we ought to consider reducing our use, having a good reason in each case.
msg12712 (view) Author: Rafal Nagrodzki (rjn) Date: 2019-10-18.13:46:19
What you call "extreme" solution I call the correct one. If there's ever a need to blend in (shade) external code into your deliverable jars, it should at least have its packages redirected in order to avoid conflict.
msg12736 (view) Author: Jeff Allen (jeff.allen) Date: 2019-11-02.10:40:11
I don't disagree.

The JAR built by this approach is here:
https://search.maven.org/artifact/org.python/jython-slim/2.7.2b2/jar

I have successfully cited it as a dependency in (very simple) Maven and Gradle projects. It be interested in knowing whether this hits the spot for more complex uses.

I do not think the original question "why so many", in the other JARs, has been answered. I'd like to reduce this to the absolute minimum in work after 2.7.2. There is perhaps not an absolutely correct way to identify that minimum.
History
Date User Action Args
2019-11-02 15:41:32jeff.allensetstatus: pending -> closed
2019-11-02 10:40:11jeff.allensetmessages: + msg12736
2019-10-18 13:46:20rjnsetmessages: + msg12712
2019-10-06 10:33:40jeff.allensetstatus: open -> pending
resolution: accepted -> fixed
messages: + msg12692
nosy: + jeff.allen
2018-03-03 16:58:23jeff.allensetkeywords: + patch
2018-03-03 16:57:47jeff.allensetkeywords: + gradle, - patch
priority: low -> normal
2017-04-12 18:34:15rjnsetmessages: + msg11303
2017-04-12 16:02:59zyasoftsetmessages: + msg11302
milestone: Jython 2.7.2
2017-04-12 12:41:30rjnsettitle: Jython jar on Maven central embedd other third party libraries -> Jython jar on Maven central embeds other third party libraries
2017-01-16 09:44:51rjnsetmessages: + msg11023
2017-01-15 23:55:10rjnsetfiles: + issue2121.patch
keywords: + patch
messages: + msg11022
nosy: + rjn
2014-10-05 17:12:48zyasoftsetpriority: low
messages: + msg9080
2014-04-07 16:36:27zyasoftsetresolution: accepted
messages: + msg8274
nosy: + zyasoft
2014-04-07 15:48:58tuskasetmessages: + msg8273
2014-04-07 15:31:29tuskasetmessages: + msg8272
2014-04-07 15:25:20tuskasetmessages: + msg8271
2014-04-07 15:24:20tuskacreate