print registered questions if debug
This commit is contained in:
parent
6f9b4678e4
commit
bb865905bf
|
@ -22,9 +22,9 @@ answers:
|
||||||
tier: 1
|
tier: 1
|
||||||
game_round: 1
|
game_round: 1
|
||||||
media:
|
media:
|
||||||
- aaa
|
- pix/question1.png
|
||||||
- bbb
|
- pix/question1_big.png
|
||||||
- ccc
|
- videos/question1.webm
|
||||||
|
|
||||||
--- !Question
|
--- !Question
|
||||||
question: What are users in Facebook called?
|
question: What are users in Facebook called?
|
||||||
|
@ -36,6 +36,6 @@ answers:
|
||||||
tier: 2
|
tier: 2
|
||||||
game_round: 1
|
game_round: 1
|
||||||
media:
|
media:
|
||||||
- aaa
|
- pix/facebook.jpg
|
||||||
- bbb
|
- pix/facebook-jail.png
|
||||||
- ccc
|
- videos/faschistbook.webm
|
||||||
|
|
|
@ -13,6 +13,7 @@ readeable format assuming yaml is more human readable
|
||||||
TODO:
|
TODO:
|
||||||
* Add own constructor to Question() / nice to have
|
* Add own constructor to Question() / nice to have
|
||||||
* Deal with media files
|
* Deal with media files
|
||||||
|
* Fix to output only questions per round as json
|
||||||
"""
|
"""
|
||||||
|
|
||||||
__author__ = "Frank Becker <fb@alien8.de>"
|
__author__ = "Frank Becker <fb@alien8.de>"
|
||||||
|
@ -178,6 +179,8 @@ def main():
|
||||||
# yaml.add_constructor
|
# yaml.add_constructor
|
||||||
Question.register_question(q)
|
Question.register_question(q)
|
||||||
questions.append(q)
|
questions.append(q)
|
||||||
|
if options.debug:
|
||||||
|
print Question.registered_questions
|
||||||
print json.dumps([q.as_dict for q in questions], indent=2)
|
print json.dumps([q.as_dict for q in questions], indent=2)
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
|
|
Loading…
Reference in New Issue
Block a user