replaced custom csv writing and some small adjustments
Hello Markwk,
I wanted to create an export of my todoist items and came across your script via Google. I've made a few adjustments after initially being unable to make it work due to a KeyError at this line below
user_completed_count = user['completed_count']
I was working on the script a bit, and thought, let's make it into a pull request. If you accept this, I could do some more work to polish a bit further. For example, I don't have a premium account, and then the script doesn't work anymore because the completed lookup fails, that's only available if you are a premium subscriber.
Anyway, this pull request shouldn't change any behaviour at the moment. Let me know if I can do something to make it acceptable for you.
-- Gijs
@Gijs-Koot I took a quick look at the commits and looks like like some nice improvements. Let me do some testing this week to confirm and then go ahead and commit these. Thanks for sharing back. Really appreciate it!
I got an error on about line 28. I think it should be:
projects.to_csv("data/todoist-projects.csv")