trello-full-backup
trello-full-backup copied to clipboard
Missing card backups
There are many cards which are present in the board's $NAME_full.json backup, but don't get their own card.json file, and their attachments aren't downloaded.
The problem is here:
cs = itertools.groupby(board_details['cards'], key=lambda x: x['idList'])
for list_id, cards in cs:
lists[list_id] = sorted(list(cards), key=lambda card: card['pos'])
This assumes that all the cards for any list are together in one batch in the board's data. If they are split up (which I've seen happen), the last batch in the itertools.groupby
overwrites any previous ones in list
, and only those cards are backed up.
This pull request fixes that.