Giter Site home page Giter Site logo

Comments (14)

petrvalkoun-gooddata avatar petrvalkoun-gooddata commented on June 19, 2024 4

Upgrade to highline 2.0 resolved the issue, thanks!

from highline.

presidentbeef avatar presidentbeef commented on June 19, 2024 2

FWIW I've been using the 2.0 development releases for JRuby compatibility for a long time.

from highline.

mkristian avatar mkristian commented on June 19, 2024 1

@headius right it is unlikely the path will change again. but it is more likely we switch to jline-3.0 one day. and current jline-3.0 has a dependency to asm which is also something jruby puts into a relocated package.

from highline.

mkristian avatar mkristian commented on June 19, 2024 1

@abinoam cool - FYI gems with native extension do not work with JRuby. Thanks for looking into all this.

from highline.

abinoam avatar abinoam commented on June 19, 2024 1

One more good new. The gem that the issue is refereeing is https://github.com/gooddata/gooddata-ruby

Having a fast look at it, it seem it is already ready for HighLine 2.0. Just because it used "best practices". It envelopes Highline use behind a local reference. Just the way HighLine 2 favors!

https://github.com/gooddata/gooddata-ruby/blob/2bd53792728329d380d96a8358cc734359c14fd5/lib/gooddata/cli/terminal.rb#L12

require 'highline'

# Define GoodData::CLI as GLI Wrapper
module GoodData
  module CLI
    DEFAULT_TERMINAL = HighLine.new unless const_defined?(:DEFAULT_TERMINAL)

    class << self
      def terminal
        DEFAULT_TERMINAL
      end
    end
  end
end

Then it uses it like this at https://github.com/gooddata/gooddata-ruby/blob/2bd53792728329d380d96a8358cc734359c14fd5/lib/gooddata/commands/auth.rb#L45

          # Read environment
          environment = GoodData::CLI.terminal.ask('Environment') do |q|
            set_default_value(q, old_credentials[:environment], GoodData::Project::DEFAULT_ENVIRONMENT)
          end

So, it seems it will probably work out of the box with HighLine 2.0 (at least for this specific gem).

from highline.

petrvalkoun-gooddata avatar petrvalkoun-gooddata commented on June 19, 2024 1

@abinoam many thanks for your help, I have already asked our developers to migrate to highline 2.0. I will notify the result.

from highline.

abinoam avatar abinoam commented on June 19, 2024

I let this up to you (@headius @mkristian) to decide what is best approach for JRuby, I think it will be easy to make Highline compatible with it 👍

PS: I'll probably have time to work on this by monday.

from highline.

abinoam avatar abinoam commented on June 19, 2024

Hi @headius,

I'm seeing now that the issue is referring to 1-7-stable branch.
These "system extensions" have gone in 2.0 (unreleased).
I'll try to have a better look at it.

from highline.

abinoam avatar abinoam commented on June 19, 2024

@tomdz Could you help on this? I saw the JRuby/jline code was made initially by you.

Hooking some other folks that could also probably help: @BanzaiMan, @ai, @presidentbeef, @rsutphin, @mnzaki, @iconoclast.

from highline.

mkristian avatar mkristian commented on June 19, 2024

just to get the initial context is play as it could be 1-7-branch related: jruby/jruby#4889

from highline.

abinoam avatar abinoam commented on June 19, 2024

just to get the initial context is play as it could be 1-7-branch related: jruby/jruby#4889

The stack trace shows that @petrvalkoun-gooddata is on 1.7.10.

initialize_system_extensions at C:/jruby/lib/ruby/gems/shared/gems/highline-1.7.10/lib/highline/system_extensions.rb:21

from highline.

abinoam avatar abinoam commented on June 19, 2024

Hi all,

I've run bundle exec rake acceptance and the readline autocomplete test worked ok on 2.0.0-pre.

I've made some simple tests on questions with readline enabled and it's woking ok on 2.0.0-pre

What about just ask @petrvalkoun-gooddata and everybody willing to keep running the most update version of JRuby to migrate his code to highline 2.0? What do you think?

By the way, I think I've postponing the 2.0 release too much. I'm waiting for feedback from people that must have their software affected by the release. But, well, I understand how hard it is to deal with legacy software. This issue afffecting JRuby is the fuel that I need to officially release 2.0.
Releasing it will push everybody that haven't set version constraints at their gemspec/Gemfiles to the most up to date HighLine version. I mean, if HighLine 2.0 was already released, perhaps this JRuby/HighLine issue wouldn't even be noticed.

Houston (@JEG2)? Agree? Release 2.0? 9, 8, 7, ...

PS:
I've had some issues trying to bundle install at 2.0.0-develop with JRuby.
Gem rugged didn't compile native extensions.
bundle install --without code_quality for the rescue. As we don't need those gems to run the tests.

from highline.

abinoam avatar abinoam commented on June 19, 2024

gems with native extension do not work with JRuby.

It is a pronto dependency.

I'll see if I can fine tune the gemspec|Gemfile so it autodetects this.

Thanks 👍

from highline.

abinoam avatar abinoam commented on June 19, 2024

I'm closing this! 👍

from highline.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.