You have a nil object when you didn’t expect it! #3

Closed
Rockyyost opened this Issue Nov 7, 2011 · 5 comments

Projects

None yet

3 participants

@Rockyyost

Hi Chris, thanks for helping!

I was trying to follow your instructions, but when I run:
ga = Gattica.new({ :email => ‘MY EMAIL’,
:password => ‘MY PASSWORD’,
:timeout => 500 })

I keep getting:

You have a nil object when you didn’t expect it!
You might have expected an instance of Array.
The error occurred while evaluating nil.split
Any idea what could be wrong?

Other then the above message, I don't get any other feed.

Thanks!

Read: Google Analytics Data Export API with Ruby + Gattica | SEER Interactive

@Rockyyost

With a little more digging, it looks like it crashes here:
/Users/ryost/.rvm/gems/ruby-1.9.3-p0/bundler/gems/gattica-15a5b28ff8d4/lib/gattica/auth.rb:46:in `parse_tokens'

@Rockyyost

This is what response looks like: #<Net::HTTPOK 200 OK readbody=true>
This is what data looks like: nil

@chrisle
Owner
chrisle commented Nov 17, 2011

Hrm. I haven't tried it under 1.9.3 yet. Have you tried using ruby 1.9.2?

@vgololobov

It works under 1.9.2 - issue is 1.9.3 Specific

@chrisle
Owner
chrisle commented Jan 31, 2012

Thanks to both of you for finding and fixing it. I incorporated it in the latest commit

@chrisle chrisle closed this Jan 31, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment