Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

failure to build logstash container due to illformed gem requirement #144

Closed
mmguero opened this issue Jan 9, 2023 · 0 comments
Closed
Assignees
Labels
bug Something isn't working build For issues related to compilation/building docker Relating to docker and docker-compose as used by Malcolm external Depends on a bug or feature external to this project logstash Relating to Malcolm's use of Logstash regression It worked at one point...

Comments

@mmguero
Copy link
Collaborator

mmguero commented Jan 9, 2023

Here's the error.

Fetching gem metadata from https://rubygems.org/.........
Resolving dependencies...
 --- ERROR REPORT TEMPLATE -------------------------------------------------------
Gem::Requirement::BadRequirementError: Illformed requirement [" < 1.60.0 (java)"]
  /usr/local/rvm/rubies/jruby-9.3.9.0/lib/ruby/stdlib/rubygems/requirement.rb:106:in `parse'
  /usr/local/rvm/rubies/jruby-9.3.9.0/lib/ruby/stdlib/rubygems/requirement.rb:138:in `block in initialize'
  org/jruby/RubyArray.java:2699:in `map!'
  /usr/local/rvm/rubies/jruby-9.3.9.0/lib/ruby/stdlib/rubygems/requirement.rb:138:in `initialize'
  org/jruby/RubyClass.java:890:in `new'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/resolver.rb:142:in `block in no_versions_incompatibility_for'
  org/jruby/RubyArray.java:2667:in `map'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/resolver.rb:142:in `no_versions_incompatibility_for'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/vendor/pub_grub/lib/pub_grub/version_solver.rb:130:in `choose_package_version'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/vendor/pub_grub/lib/pub_grub/version_solver.rb:41:in `work'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/vendor/pub_grub/lib/pub_grub/version_solver.rb:58:in `solve'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/resolver.rb:76:in `solve_versions'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/resolver.rb:37:in `start'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/definition.rb:554:in `start_resolution'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/definition.rb:279:in `resolve'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/definition.rb:177:in `resolve_remotely!'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/installer.rb:261:in `resolve_if_needed'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/installer.rb:82:in `block in run'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/process_lock.rb:12:in `block in lock'
  org/jruby/RubyIO.java:1148:in `open'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/process_lock.rb:9:in `lock'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/installer.rb:71:in `run'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/installer.rb:23:in `install'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/cli/install.rb:62:in `run'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/cli.rb:260:in `block in install'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/settings.rb:131:in `temporary'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/cli.rb:259:in `install'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/vendor/thor/lib/thor.rb:392:in `dispatch'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/cli.rb:34:in `dispatch'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/vendor/thor/lib/thor/base.rb:485:in `start'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/cli.rb:28:in `start'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/exe/bundle:45:in `block in <main>'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/lib/bundler/friendly_errors.rb:117:in `with_friendly_errors'
  /usr/local/rvm/gems/jruby-9.3.9.0/gems/bundler-2.4.3/exe/bundle:33:in `<main>'
  org/jruby/RubyKernel.java:1052:in `load'
  /usr/local/rvm/gems/jruby-9.3.9.0/bin/bundle:23:in `<main>'
  org/jruby/RubyKernel.java:1091:in `eval'
  /usr/local/rvm/gems/jruby-9.3.9.0/bin/jruby_executable_hooks:22:in `<main>'

Environment

Bundler             2.4.3
  Platforms         ruby, universal-java-1.8
Ruby                2.6.8p0 (2022-10-24 revision 67951) [universal-java-1.8]
  Full Path         /usr/local/rvm/rubies/jruby-9.3.9.0/bin/jruby
  Config Dir        /usr/local/rvm/rubies/jruby-9.3.9.0/etc
RubyGems            3.2.33
  Gem Home          /usr/local/rvm/gems/jruby-9.3.9.0
  Gem Path          /usr/local/rvm/gems/jruby-9.3.9.0:/usr/local/rvm/rubies/jruby-9.3.9.0/lib/ruby/gems/shared
  User Home         /root
  User Path         /root/.local/share/gem/jruby/2.6.0
  Bin Dir           /usr/local/rvm/gems/jruby-9.3.9.0/bin
OpenSSL             
  Compiled          JRuby-OpenSSL 0.14.0
  Loaded            JRuby-OpenSSL 0.14.0
  Cert File         /etc/pki/tls/certs/ca-bundle.crt
  Cert Dir          /etc/ssl/certs
Tools               
  Git               not installed
  RVM               1.29.12-next (master)
  rbenv             not installed
  chruby            not installed
  rubygems-bundler  (1.4.5)

Bundler Build Metadata

Built At          2023-01-06
Git SHA           ed1f27f75c
Released Version  true

Gemfile

Gemfile

source 'https://rubygems.org'

gemspec

logstash_path = ENV["LOGSTASH_PATH"] || "../../logstash"
use_logstash_source = ENV["LOGSTASH_SOURCE"] && ENV["LOGSTASH_SOURCE"].to_s == "1"

if Dir.exist?(logstash_path) && use_logstash_source
  gem 'logstash-core', :path => "#{logstash_path}/logstash-core"
  gem 'logstash-core-plugin-api', :path => "#{logstash_path}/logstash-core-plugin-api"
end

Gemfile.lock

<No /opt/logstash-filter-fingerprint/Gemfile.lock found>

Gemspecs

logstash-filter-fingerprint.gemspec

Gem::Specification.new do |s|

  s.name            = 'logstash-filter-fingerprint'
  s.version         = '3.4.1'
  s.licenses        = ['Apache-2.0']
  s.summary         = "Fingerprints fields by replacing values with a consistent hash"
  s.description     = "This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program"
  s.authors         = ["Elastic"]
  s.email           = '[email protected]'
  s.homepage        = "http://www.elastic.co/guide/en/logstash/current/index.html"
  s.require_paths = ["lib"]

  # Files
  s.files = Dir["lib/**/*","spec/**/*","*.gemspec","*.md","CONTRIBUTORS","Gemfile","LICENSE","NOTICE.TXT", "vendor/jar-dependencies/**/*.jar", "vendor/jar-dependencies/**/*.rb", "VERSION", "docs/**/*"]

  # Tests
  s.test_files = s.files.grep(%r{^(test|spec|features)/})

  # Special flag to let us know this is actually a logstash plugin
  s.metadata = { "logstash_plugin" => "true", "logstash_group" => "filter" }

  # Gem dependencies
  s.add_runtime_dependency "logstash-core-plugin-api", ">= 1.60", "<= 2.99"
  s.add_runtime_dependency "murmurhash3"                    #(MIT license)
  s.add_development_dependency 'logstash-devutils'
  s.add_runtime_dependency 'logstash-mixin-ecs_compatibility_support'
end
--- TEMPLATE END ----------------------------------------------------------------

Unfortunately, an unexpected error occurred, and Bundler cannot continue.

First, try this link to see if there are any existing issue reports for this error:
https://github.com/rubygems/rubygems/search?q=Illformed+requirement+%5B%22

Rather than go down the rabbit hole I realized I no longer need to build this from, source. I'm just going to install it the regular way now.

@mmguero mmguero self-assigned this Jan 9, 2023
@mmguero mmguero added bug Something isn't working docker Relating to docker and docker-compose as used by Malcolm external Depends on a bug or feature external to this project logstash Relating to Malcolm's use of Logstash build For issues related to compilation/building regression It worked at one point... labels Jan 9, 2023
@mmguero mmguero added this to Malcolm Jan 9, 2023
@mmguero mmguero closed this as completed in 344444e Jan 9, 2023
@github-project-automation github-project-automation bot moved this to Done in Malcolm Jan 9, 2023
@mmguero mmguero moved this from Done to Released in Malcolm Feb 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working build For issues related to compilation/building docker Relating to docker and docker-compose as used by Malcolm external Depends on a bug or feature external to this project logstash Relating to Malcolm's use of Logstash regression It worked at one point...
Projects
Status: Released
Development

No branches or pull requests

1 participant