mkristian / jar-dependencies

manage jar dependencies for ruby gems
MIT License
34 stars 19 forks source link

Update ruby/maven infrastructure and get integration tests passing #84

Open headius opened 2 weeks ago

headius commented 2 weeks ago

I am attempting to update the ruby/maven infrastructure but running into problems getting everything sorted.

[INFO] [WARNING] The POM for rubygems:jar-dependencies:gem:0.5.0 is invalid, transitive dependencies (if any) will not be available: 1 problem was encountered while building the effective model
[INFO] [FATAL] Non-parseable POM /Users/headius/.m2/repository/rubygems/jar-dependencies/0.5.0/jar-dependencies-0.5.0.pom: in epilog non whitespace content is not allowed but got \u0 (position: END_TAG seen ...</build>\n</project>\n\u0... @85:2)  @ line 85, column 2
[INFO] [INFO] Downloading from mavengems: mavengem:https://rubygems.org/rubygems/adamantium/maven-metadata.xml
[INFO] [INFO] Downloading from central: https://repo.maven.apache.org/maven2/rubygems/adamantium/maven-metadata.xml
[INFO] [INFO] Downloaded from mavengems: mavengem:https://rubygems.org/rubygems/adamantium/maven-metadata.xml (604 B at 25 kB/s)
[INFO] [WARNING] Could not transfer metadata rubygems:adamantium/maven-metadata.xml from/to maven-default-http-blocker (http://0.0.0.0/): Blocked mirror for repositories: [rubygems-prereleases (http://rubygems-proxy.torquebox.org/prereleases, default, snapshots)]
[INFO] [INFO] --- exec:3.5.0:exec (default) @ bundle_with_path ---
[INFO] Gem::LoadError: can't activate jar-dependencies-0.5.0, already activated jar-dependencies-0.4.1
[INFO]   check_version_conflict at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/specification.rb:2278
[INFO]                 activate at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/specification.rb:1415
[INFO]                      gem at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_gem.rb:68
[INFO]              synchronize at org/jruby/ext/thread/Mutex.java:171
[INFO]                      gem at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_gem.rb:68
[INFO]                   <main> at bundle.rb:6
[INFO] [ERROR] Command execution failed.

Given the many old versions that I'm trying to update (all pushed to master) I don't believe the integration tests were passing before, but I want to get them passing before I release the updated jar-dependencies.

@mkristian I could use your help here... not sure where I am missing configs to get these integration tests working.

headius commented 2 weeks ago

@mkristian Looks like the polyglot jars did not get into the ruby-maven gem... is that something I have to do manually before releasing?

https://github.com/mkristian/jar-dependencies/actions/runs/11581620742/job/32242788552#step:5:22

headius commented 2 weeks ago

I have yanked ruby-maven-3.9.0 for now to avoid users hitting a broken release.

mkristian commented 2 weeks ago

@headius did you use maven to build the gem (and deploy it tu rubygems.org ) ? https://github.com/jruby/ruby-maven?tab=readme-ov-file#building

headius commented 2 weeks ago

@mkristian Yes I believe that I followed the instructions in README.

jsvd commented 6 days ago

@mkristian Looks like the polyglot jars did not get into the ruby-maven gem... is that something I have to do manually before releasing?

Not sure if this helps, but the jar is there (3.9.0.pre1 is the same size as the yanked 3.9.0 - 100kb):

❯ gem fetch ruby-maven -v 3.9.0.pre1
Downloaded ruby-maven-3.9.0.pre1

❯ gem unpack ruby-maven-3.9.0.pre1.gem
Unpacked gem: 'ruby-maven-3.9.0.pre1'

❯ find ruby-maven-3.9.0.pre1 -name "*.jar" 
ruby-maven-3.9.0.pre1/lib/extensions/polyglot-ruby-0.7.1.jar
ruby-maven-3.9.0.pre1/lib/extensions/polyglot-common-0.7.1.jar

The CI mentions:

Errno::ENOENT: No such file or directory - /home/runner/work/jar-dependencies/jar-dependencies/vendor/bundle/jruby/3.1.0/gems/ruby-maven-3.9.0/lib/polyglot_jars

So I don't see how the jars can go from lib/extensions to lib/polyglot_jars. either there's nothing moving them there, or if there's code to do it, it's broken.