Tuesday, June 25, 2013

revoltdc hackathon 20130622 [iteration 1 a] clues

You should never ever block your developers from IRC, if you do, you don't understand development well enough

[19:38] <memomemo> I'd like to know the proper way to call meteor.apply
[19:39] <memomemo> my project is completely public
[19:39] <memomemo> https://github.com/meyilmaz/revoltdc_hackathon20130622_continued
[19:39] == someone [~] has left #meteor []
[19:39] <a person> it's the same as meteor.call except the arguments are given as an array
[19:39] <memomemo> well in my project
[19:40] <memomemo> I am trying to hit the sunlight api in two subsequent calls from the meteor server in a meteor method
[19:40] <memomemo> the second call is dependent on the first
[19:40] <a person> ok
[19:40] <memomemo> this is an http.call
[19:40] <a person> you want fibers probably
[19:40] <a person>> memomemo:  https://gist.github.com/possibilities/3443021
[19:41] <memomemo> ok, but are you aware I am looking to run them one following the other? I need data from the first call?
[19:41] <a person> did you look at that url
[19:41] <a person> it explains how to do that
[19:42] <memomemo> awesome thanks so much

Unfortunately this doesn't help, even though it is good info. Turns out futures was basically cut, but perhaps this is a good point to review fibers in eventedmind

RevoltDC Hackathon 20130622 [Iteration 1] {Fail}

Two notes here

  • Removing unblock doesn't solve the problem
  • Using meteor apply isn't obvious enough on how to get the function working with options

Maybe I'll check freenode

Get a picture if you are following along the changeset is here

Server prints data fine and executes fine, doing to calls to the sunlight api (call is shortened)

Gardner is query
G000562
[ { tfidf: 0.00161716760949, count: 72, ngram: 'colorado' },
  { tfidf: 0.000431216731236, count: 58, ngram: 'energy' },
  { tfidf: 0.000168406409022, count: 55, ngram: 'jobs' },
  { tfidf: 0.000279620851672, count: 32, ngram: 'debt' },
  { tfidf: 0.000443389920289, count: 27, ngram: 'oil' },
  { tfidf: 0.000590425270757, count: 19, ngram: 'they\'re' },
  { tfidf: 0.000197000043001, count: 16, ngram: 'regulations' },
  { tfidf: 0.000158407422796, count: 14, ngram: 'creation' },
  { tfidf: 0.000745681911791, count: 14, ngram: 'permitting' },
  { tfidf: 0.000182821819519, count: 13, ngram: 'i\'m' },
 ]