ryantate/typingpool

tp-finish issue

Closed this issue · 1 comments

I realized this is a different issue than the previous issue so I copy and pasted here. Thanks again for your help.

Here's the workflow I did. You can see what happens after "tp-finish".


XXXXXXXs-MacBook-Pro:~ XXXXXXX$ tp-make "test2" a.wav --chunks 00:30
Converting a.wav to mp3
Splitting audio into uniform bits
Uploading test2.00.00.mp3 to typingpool-htlxb1i9p8ut47hb.s3.amazonaws.com/ as test2.00.00.2b8ed93330e3e53d9f2aa2e4e3ef7967.GEGTPG.mp3
Uploading test2.00.30.mp3 to typingpool-htlxb1i9p8ut47hb.s3.amazonaws.com/ as test2.00.30.2b8ed93330e3e53d9f2aa2e4e3ef7967.MDIVYX.mp3
Uploading test2.01.00.mp3 to typingpool-htlxb1i9p8ut47hb.s3.amazonaws.com/ as test2.01.00.2b8ed93330e3e53d9f2aa2e4e3ef7967.EVDAIV.mp3
Opening project folder /Users/XXXXXXX/Desktop/Transcripts/test2
Done. Project at:
/Users/XXXXXXX/Desktop/Transcripts/test2

XXXXXXXs-MacBook-Pro:~ XXXXXXX$ tp-assign "test2" speech --sandbox
Figuring out what needs to be assigned
3 assignments total
3 assignments to assign
Deleting old assignment HTML from typingpool-htlxb1i9p8ut47hb.s3.amazonaws.com
Uploading assignment HTML to typingpool-htlxb1i9p8ut47hb.s3.amazonaws.com
Assigning (in sandbox)
Assigned transcription job for 'test2.00.00.mp3'
Assigned transcription job for 'test2.00.30.mp3'
Assigned transcription job for 'test2.01.00.mp3'
Assigned 3 transcription jobs for $0.00

XXXXXXXs-MacBook-Pro:~ XXXXXXX$ tp-finish "test2" --sandbox
Removing from Amazon
Collecting all results
/Users/XXXXXXX/.rvm/rubies/ruby-1.9.3-p429/lib/ruby/1.9.1/open-uri.rb:346:in open_http': 404 Not Found (OpenURI::HTTPError) from /Users/XXXXXXX/.rvm/rubies/ruby-1.9.3-p429/lib/ruby/1.9.1/open-uri.rb:775:inbuffer_open'
from /Users/XXXXXXX/.rvm/rubies/ruby-1.9.3-p429/lib/ruby/1.9.1/open-uri.rb:203:in block in open_loop' from /Users/XXXXXXX/.rvm/rubies/ruby-1.9.3-p429/lib/ruby/1.9.1/open-uri.rb:201:incatch'
from /Users/XXXXXXX/.rvm/rubies/ruby-1.9.3-p429/lib/ruby/1.9.1/open-uri.rb:201:in open_loop' from /Users/XXXXXXX/.rvm/rubies/ruby-1.9.3-p429/lib/ruby/1.9.1/open-uri.rb:146:inopen_uri'
from /Users/XXXXXXX/.rvm/rubies/ruby-1.9.3-p429/lib/ruby/1.9.1/open-uri.rb:677:in open' from /Users/XXXXXXX/.rvm/rubies/ruby-1.9.3-p429/lib/ruby/1.9.1/open-uri.rb:33:inopen'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit/full.rb:59:in external_question' from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit/full.rb:70:inexternal_question_param'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:430:in stashed_param' from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:246:inurl'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:295:in ours?' from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:145:inblock in all_for_project'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:225:in call' from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:225:inblock in filter_ours'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:224:in select' from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:224:infilter_ours'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:164:in all' from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/lib/typingpool/amazon/hit.rb:145:inall_for_project'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/gems/typingpool-0.8.3/bin/tp-finish:53:in <top (required)>' from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/bin/tp-finish:19:inload'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/bin/tp-finish:19:in <main>' from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/bin/ruby_noexec_wrapper:14:ineval'
from /Users/XXXXXXX/.rvm/gems/ruby-1.9.3-p429/bin/ruby_noexec_wrapper:14:in `

'
XXXXXXXs-MacBook-Pro:~ XXXXXXX$

Thanks for the bug report! Apologies, this is another oversight of mine in the code that iterates through all the HITs in your Mechanical Turk account - I failed to account for the possibility of non-Typingpool HITs with external question URLs that resolve to unsuccessful HTTP requests (404 missing, etc).

This issue has been fixed in this commit: 4d02b31

The fix has also been pushed to rubygems, so if you run gem install typingpool you should get the version in which this is fixed (0.8.4).

(In the future I'll fix tp-finish so it does not always need to iterate through all the HITs in your account. In the common case -- HITs assigned through the Typingpool scripts -- this should not be necessary as we can just walk the HIT ids in data/assignments.csv. It's only necessary to look through your whole account when you've assigned the HITs via the Amazon Mechanical Turk RUI, but no one seems to be doing that.)