ArgumentError in fetch.rb:26
Closed this issue · 3 comments
MattWindsor91 commented
Hey, was trying to compile a fairly recent (dfc6195b) compile of cargo using fakeCargo a218e97 on ruby 2.1.5 and got this:-
processing ./rust-url/Cargo.toml
{"package"=>
{"name"=>"url",
"version"=>"0.2.5",
"authors"=>["Simon Sapin <simon.sapin@exyr.org>"],
"description"=>"URL parser for Rust",
"documentation"=>"http://servo.github.io/rust-url/url/index.html",
"repository"=>"https://github.com/servo/rust-url",
"readme"=>"README.md",
"keywords"=>["url", "parser"],
"license"=>"MIT/Apache-2.0"},
"features"=>{"query_encoding"=>["encoding"]},
"dependencies"=>{"encoding"=>{"version"=>"0.2", "optional"=>true}}}
/home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/lib/fakeCargo/fetch.rb:26:in `fetch': w
rong number of arguments (3 for 1..2) (ArgumentError)
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/lib/fakeCargo/fetch.rb:26:
in `fetch'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:29:in `block
in process_file'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:28:in `each'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:28:in `proce
ss_file'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:30:in `block
in process_file'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:28:in `each'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:28:in `proce
ss_file'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:21:in `root_
file'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:81:in `block
in <top (required)>'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:80:in `each'
from /home/mattbw/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/fakeCargo-0.0.1/bin/fakeCargo:80:in `<top
(required)>'
from /home/mattbw/.rbenv/versions/2.1.5/bin/fakeCargo:23:in `load'
from /home/mattbw/.rbenv/versions/2.1.5/bin/fakeCargo:23:in `<main>'
Haven't looked yet to figure out what's going on with fetch
, but something about this crate makes fakeCargo unhappy!
aidancully commented
It looks like cargo now requires crates from crates.io to build successfully. fakeCargo didn't support those... Looking at this now.
aidancully commented
Somewhat resolved in version 0.0.2, which I just committed. It now provides instructions for downloading crates from crates.io (it doesn't download automatically, since I don't currently handle crate versioning well right now.) Let me know how it works for you.
aidancully commented
Closing this - I believe it's been addressed.