# Gem installation problem on windows

**URL:** <https://www.ruby-forum.com/t/gem-installation-problem-on-windows/180067>\
**Category:** Ruby\
**Created:** [December 10, 2009, 5:30pm UTC](https://www.ruby-forum.com/t/gem-installation-problem-on-windows/180067 "2009-12-10T17:30:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [December 10, 2009, 5:30pm UTC](https://www.ruby-forum.com/t/gem-installation-problem-on-windows/180067/1 "2009-12-10T17:30:34Z")

</div>

i have installed ruby successfully.  
When i am installing any gem then it shows the error  
the trace is give as below:-  
please give the solution .  
Thanks in advance

C:\Documents and Settings\karriren\>gem install rhodes --remote --debug  
Exception `NameError' at d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/ command_manager .rb:134 - uninitialized constant Gem::Commands::InstallCommand Exception`URI::InvalidURIError’ at d:/Ruby/lib/ruby/1.8/uri/  
generic.rb:195 - th  
e scheme http does not accept registry part:  
username:password@host:port (or bad  
hostname?)  
ERROR: While executing gem … (URI::InvalidURIError)  
the scheme http does not accept registry part:  
username:password@host:port (  
or bad hostname?)  
d:/Ruby/lib/ruby/1.8/uri/generic.rb:195:in `initialize' d:/Ruby/lib/ruby/1.8/uri/http.rb:78:in`initialize’  
d:/Ruby/lib/ruby/1.8/uri/common.rb:488:in `new' d:/Ruby/lib/ruby/1.8/uri/common.rb:488:in`parse’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/remote\_fetcher.rb:  
180:in `get_pr oxy_from_env' d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/remote_fetcher.rb: 66:in`initial  
ize’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/remote\_fetcher.rb:  
44:in `new' d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/remote_fetcher.rb: 44:in`fetcher  
’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/spec\_fetcher.rb:46:in  
`initializ e' d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/spec_fetcher.rb:32:in`new’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/spec\_fetcher.rb:32:in  
`fetcher' d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/ dependency_installer.rb:96:in`f  
ind\_gems\_with\_sources’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/  
dependency\_installer.rb:189:in `find_spec_by_name_and_version' d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/ dependency_installer.rb:210:in`  
install’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/commands/  
install\_command.rb:86:i  
n `execute' d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/commands/ install_command.rb:83:i n`each’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/commands/  
install\_command.rb:83:i  
n `execute' d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/command.rb:136:in`invoke’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/command\_manager.rb:  
105:in `proce ss_args' d:/Ruby/lib/ruby/site_ruby/1.8/rubygems/command_manager.rb: 75:in`run’  
d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/gem\_runner.rb:39:in  
`run’  
d:/Ruby/bin/gem:24

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [December 10, 2009, 7:03pm UTC](https://www.ruby-forum.com/t/gem-installation-problem-on-windows/180067/2 "2009-12-10T19:03:38Z")

</div>

On Thu, Dec 10, 2009 at 4:30 PM, removed\_email\_address@domain.invalid  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> i have installed ruby successfully.  
> When i am installing any gem then it shows the error  
> the trace is give as below:-  
> please give the solution .  
> Thanks in advance

What version of Ruby have you installed, in particular have you  
installed  
the older Ruby 1-Click installer, or  
have you used the RubyInstaller binaries for windows? The version of  
gems  
that ships with the Ruby 1-Click  
installer is pointing to the old RubyForge gem repository. I think the  
RubyInstaller has been updated to  
point to the new repository on [gemcutter.org](http://gemcutter.org).

If you do  
gem source -a [http://gemcutter.org](http://gemcutter.org)  
it might point you to the new repo.

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [December 10, 2009, 9:05pm UTC](https://www.ruby-forum.com/t/gem-installation-problem-on-windows/180067/3 "2009-12-10T21:05:56Z")

</div>

On Dec 10, 1:28 pm, “removed\_email\_address@domain.invalid” [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Exception `URI::InvalidURIError' at d:/Ruby/lib/ruby/1.8/uri/ d:/Ruby/lib/ruby/1.8/uri/common.rb:488:in `new’  
> 44:in `fetcher ind_gems_with_sources' install_command.rb:83:i 75:in `run’  
> d:/Ruby/lib/ruby/site\_ruby/1.8/rubygems/gem\_runner.rb:39:in  
> `run’  
> d:/Ruby/bin/gem:24

can you tell us if you’re behind an HTTP proxy?

For the error, looks like, and the URL used by it do not conform a  
valid URL schema.

Please paste the output of “SET HTTP\_PROXY” so we can take a look to  
the value.
