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

Problem with requesting password from console #19

Open
rnowosielski opened this issue Mar 9, 2016 · 5 comments
Open

Problem with requesting password from console #19

rnowosielski opened this issue Mar 9, 2016 · 5 comments

Comments

@rnowosielski
Copy link

When I try to use Zanzibar 0.1.21 calling

sec = Zanzibar::Zanzibar.new(:domain => '****',
    :wsdl => "****",
    :globals => { ssl_verify_mode: :none } )

I get in this line an error with the following stack

$ rake develop --trace
** Invoke develop (first_time)
** Invoke setup_secrets (first_time)
** Execute setup_secrets
rake aborted!
Errno::EBADF: Bad file descriptor
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/zanzibar-0.1.21/lib/zanzibar.rb:69:in `noecho'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/zanzibar-0.1.21/lib/zanzibar.rb:69:in `prompt_for_password'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/zanzibar-0.1.21/lib/zanzibar.rb:34:in `initialize'
D:/StepCheck/Rakefile:175:in `new'
D:/StepCheck/Rakefile:175:in `block in <top (required)>'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:248:in `call'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:248:in `block in execute'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:243:in `each'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:243:in `execute'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:187:in `block in    invoke_with_call_chain'
C:/Ruby22-x64/lib/ruby/2.2.0/monitor.rb:211:in `mon_synchronize'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:180:in `invoke_with_call_chain'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:209:in `block in invoke_prerequisites'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:207:in `each'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:207:in `invoke_prerequisites'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:186:in `block in invoke_with_call_chain'
C:/Ruby22-x64/lib/ruby/2.2.0/monitor.rb:211:in `mon_synchronize'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:180:in `invoke_with_call_chain'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/task.rb:173:in `invoke'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:150:in `invoke_task'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:106:in `block (2 levels) in top_level'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:106:in `each'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:106:in `block in top_level'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:115:in `run_with_threads'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:100:in `top_level'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:78:in `block in run'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:176:in `standard_exception_handling'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/lib/rake/application.rb:75:in `run'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.0.1/bin/rake:33:in `<top (required)>'
C:/Ruby22-x64/bin/rake:23:in `load'
C:/Ruby22-x64/bin/rake:23:in `<main>'
Tasks: TOP => develop => setup_secrets
Please enter password for ***:
@rnowosielski
Copy link
Author

The issue happens on Windows 7 with MINGW console.

@maclennann
Copy link
Collaborator

Thanks for the report, Rafal. My first guess is that the mingw console has some kind of trouble with io/console.

I'll see if I can get a Windows box up to repro. If that's the problem, it's probably pretty easy to swap out for highline or something else that's higher level.

@maclennann
Copy link
Collaborator

It looks like this issue effects HighLIne as well, since it uses io/console under the hood. So there's probably nothing much we can do here. Does the workaround at the bottom of the linked issue mean anything to you?

I'm going to leave this issue open, but don't plan on doing any work on it to support this one terminal type on one operating system, but if you find something that works feel free to file a PR or let us know.

@jeremypaskalicimpress
Copy link

I'm experiencing this same issue on Windows 7 with MINGW console. The workaround for me is to use the command prompt.

@LexVocoder
Copy link

LexVocoder commented Apr 25, 2018

In git bash, I got past this particular error with the following:
winpty -- "$(which ruby)" "$(which zanzibar)" get --wsdl=...
@maclennann

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants