6a0c28dff9490c90e5c58301b8e81b74f3433424,parlai/mturk/core/agents.py,MTurkManager,approve_work,#MTurkManager#Any#,236

Before Change


        print("All reviews are done!\n")

    def approve_work(self, assignment_id):
        client = boto3.client(
            service_name = "mturk", 
            region_name = "us-east-1",
            endpoint_url = "https://mturk-requester-sandbox.us-east-1.amazonaws.com"
        )
        // Region is always us-east-1
        if not self.is_sandbox:
            client = boto3.client(service_name = "mturk", region_name="us-east-1")

        client.approve_assignment(AssignmentId=assignment_id)

    def reject_work(self, assignment_id):
        client = boto3.client(

After Change


            print("Waiting for Turkers to respond... (Please don"t close your laptop or put your computer into sleep or standby mode.)\n")

    def approve_work(self, assignment_id):
        client = get_mturk_client(self.is_sandbox)
        client.approve_assignment(AssignmentId=assignment_id)

    def reject_work(self, assignment_id):
        client = get_mturk_client(self.is_sandbox)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 11

Instances


Project Name: facebookresearch/ParlAI
Commit Name: 6a0c28dff9490c90e5c58301b8e81b74f3433424
Time: 2017-07-09
Author: willfeng@fb.com
File Name: parlai/mturk/core/agents.py
Class Name: MTurkManager
Method Name: approve_work


Project Name: facebookresearch/ParlAI
Commit Name: 6a0c28dff9490c90e5c58301b8e81b74f3433424
Time: 2017-07-09
Author: willfeng@fb.com
File Name: parlai/mturk/core/agents.py
Class Name: MTurkManager
Method Name: reject_work


Project Name: facebookresearch/ParlAI
Commit Name: 6a0c28dff9490c90e5c58301b8e81b74f3433424
Time: 2017-07-09
Author: willfeng@fb.com
File Name: parlai/mturk/core/agents.py
Class Name: MTurkManager
Method Name: block_worker


Project Name: facebookresearch/ParlAI
Commit Name: 6a0c28dff9490c90e5c58301b8e81b74f3433424
Time: 2017-07-09
Author: willfeng@fb.com
File Name: parlai/mturk/core/agents.py
Class Name: MTurkManager
Method Name: approve_work