Sfoglia il codice sorgente

Fix data reversal.

tags/v0.1^2
Ben Kurtovic 13 anni fa
parent
commit
2f86fe5b07
1 ha cambiato i file con 2 aggiunte e 1 eliminazioni
  1. +2
    -1
      bot/tasks/afc_history.py

+ 2
- 1
bot/tasks/afc_history.py Vedi File

@@ -86,8 +86,9 @@ class Task(BaseTask):
date = category.title().split("/")[-1]
data[date] = self.get_date_counts(date)

data = OrderedDict(reversed(data.items())) # Oldest to most recent
self.generate_chart(data)
dest = expanduser(self.destination)
self.generate_chart(reversed(data))
plt.savefig(dest)
self.logger.info("Chart saved to {0}".format(dest))



Caricamento…
Annulla
Salva