data = {"id": int(play.attrib["id"]),
"date": play.attrib["date"],
"quantity": int(play.attrib["quantity"]),
"duration": int(play.attrib["length"]),
"location":play.attrib["location"],
"incomplete": int(play.attrib["incomplete"]),
"nowinstats": int(play.attrib["nowinstats"]),
# for User plays, will be overwritten with the user id when adding the play.
"user_id": int(play.attrib.get("userid", -1)),
"game_id": xml_subelement_attr(play, "item", attribute="objectid", convert=int),
"game_name": xml_subelement_attr(play, "item", attribute="name"),
"comment": xml_subelement_text(play, "comments"),
"players": player_list}`
Hello,
I think, there is a issue when searching a location in a played game session.
The location information is empty when you get a bgg play session
The procedure add_play_from_xml seems to search data on the player item.
I 've changed the loaders/play.py to avoid this issue.
line 60 : add "location":play.attrib["location"], in the add_play_from_xml procedure