- CloudModel is actually classed correctly
- Minify JSON prior to uploading
- Change archive update interval to 24h (30* ..20MB = 600/1000MB)
- Store latest revision url for archive/model after persisting
TODO:
- Add INITIAL_CORPUS_FILE config var
- Look for Cloudinary API call to get filesize w/o DLing
- Logic for jsonify(INTIIAL_CORPUS_FILE) v. using persisted archive
- Add fetch/persist/etc methods to Ebooks::Archive/Model for fallback
- Test it? Or just share it and pray.
Move Cloudinary require/calls to boodoo.rb
Add upload_archive, upload_model, fetch_archive, fetch_model
rename get_archive! to update_archive!
TODO:
- Learn how to load model from content instead of File.open
- Come up with sensible check/update logic
Tweets determined as 'special' to the bot could (under a 50% chance) accidentally attempt to be favourited twice, causing a crash due to Twitter returning a Forbidden response. In this example, we add an assertion to check whether the earlier favourite has occurred, to prevent it happening again.