Skip to content

Commit

Permalink
More debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
peat committed Feb 12, 2012
1 parent 182e4f3 commit 8fef321
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 0 additions & 1 deletion extension/scraper.js
Expand Up @@ -26,7 +26,6 @@ AH.processQueue = function() {
var msg = AH.queue.shift() // off the front; opposite of pop()
jQuery.post( msg.url, msg.request, function(data) {
setTimeout("AH.processQueue()", 100); // try running again
AH.log("Response: " + data);
});
} else {
setTimeout("AH.processQueue()", 10000); // check in 10 seconds
Expand Down
5 changes: 3 additions & 2 deletions server/lib/grind.rb
Expand Up @@ -67,15 +67,16 @@ def grind_soundcloud( url )
begin
raw_follow = "http://api.soundcloud.com/resolve.json?client_id=#{SOUNDCLOUD_CLIENT_ID}&url=#{URI.escape(url.to_s)}"
follow = URI.parse( raw_follow )
puts "XXX follow: #{follow.to_s}, lookup_url: #{lookup_url}"
puts "XXX follow: #{follow.to_s}"
data = JSON.parse( open( follow.to_s ).read )
puts "XXX follow: #{data.to_s}"
treasure = {
:track => data['title'],
:artist => data['user']['username'],
:provider => 'Soundcloud',
}

[treasure]
return [treasure]
rescue =>e
puts "#{e}, follow: #{follow.to_s}, lookup_url: #{lookup_url}"
end
Expand Down

0 comments on commit 8fef321

Please sign in to comment.