how to set up Sandbox locally

125 views
Skip to first unread message

Бота Акболина

unread,
Jul 30, 2020, 9:16:59 PM7/30/20
to oTree help & discussion
Hi everyone!

Could you, please, explain how to set up Sandbox locally? I followed instruction https://otree.readthedocs.io/en/latest/mturk.html#mturk and struggle with this part. I searched here and I have changed settings.py like this:

from os import environ

# if you set a property in SESSION_CONFIG_DEFAULTS, it will be inherited by all configs
# in SESSION_CONFIGS, except those that explicitly override it.
# the session config can be accessed from methods in your apps as self.session.config,
# e.g. self.session.config['participation_fee']

AWS_ACCESS_KEY_ID = environ.get('AWS_ACCESS_KEY_ID')
AWS_SECRET_ACCESS_KEY = environ.get('AWS_SECRET_ACCESS_KEY')

SANDBOX = environ.get('SANDBOX')

SESSION_CONFIG_DEFAULTS = dict(
real_world_currency_per_point=1.00,
participation_fee=0.00,
doc=""
)

mturk_hit_settings = dict(
keywords='bonus, study',
title='Title for your experiment',
description='Description for your experiment',
frame_height=500,
template='global/mturk_template.html',
minutes_allotted_per_assignment=60,
expiration_hours=7 * 24,
qualification_requirements=[]

I added AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY to system variables but not on heroku yet (becouse I want to test locally).
 
My questions:
1. When I create locall Mturk session I have message that I didn't set AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY. Do I miss something?
2. How to set up Sandbox locally?

Thank you in advance.

Gonzalo Arrieta

unread,
Mar 15, 2021, 7:25:55 PM3/15/21
to oTree help & discussion
I second this, ...same issues here.

Gonzalo Arrieta

unread,
Mar 15, 2021, 7:33:24 PM3/15/21
to oTree help & discussion
I am not using oTree Studio and I'm using the old models.py format. The instructions that the documentation takes me to are non-existent: https://github.com/oTree-org/otree-docs/blob/master/source/misc/mturk_newformat.rst

Help?

Reply all
Reply to author
Forward
0 new messages