oTree Forum >

self.load_from_disk(filename, template_type=template_type) Error when starting HIT on Mturk - using OTREE Studio

#1 by JuergenMR

Hey everyone, 

I have created an experiment in OTREE Studio and deployed it to Heroku, and everything works fine. Except when I want to run it on mturk I get the following error from Sentry - before, I had to delete OTREE_PRODUCTION in the config_vars, otherwise, it would have stopped even before:

TemplateSyntaxError: Unexpected tag (line 47, in "endblock")
(26 additional frame(s) were not displayed)
...
  File "otree/templating/loader.py", line 19, in load
    template, path = self.load_from_disk(filename, template_type=template_type)
  File "otree/templating/loader.py", line 40, in load_from_disk
    template = Template(template_string, template_id, template_type=template_type)
  File "otree/templating/template.py", line 12, in __init__
    self.root_node = compiler.compile(
  File "otree/templating/compiler.py", line 16, in compile
    return Parser(
  File "otree/templating/compiler.py", line 149, in parse
    raise errors.TemplateSyntaxError(msg, token)

#2 by JuergenMR

I think this is related to the problem above

#3 by Chris_oTree

Can you show your template code? It looks like your block tags are not balanced. You shouldn’t have any block tags in your code.

#4 by JuergenMR

thanks 1000 times! stupid and so easy to avoid! Have a great weekend and thanks for your support!

Write a reply

Set forum username