Day 23

August 2, 2017 14:54 UTC Team berlin diamonds (Discourse) [2017]Subscribe to this teams's activities


  • Created a simple ruby script that uploads files to Dropbox to understand its API.
  • Learnt about Ruby constants: When loading the file dropboxsyncrhonizer.rb in the console, I kept getting the error `"warning: already initialized constant DiscourseBackupToDropbox::DropboxSynchronizer::CHUNKSIZE". Related to the constantCHUNK_SIZE = 25600000`. The program was trying to reassign the same value to the existent constant and Ruby complained, the double pipe/or equals ||= solves the issue because it checks to see if the value on the left is defined, then uses that. If it's not, uses the value on the right.
  • Read about debugging with pry (binding.pry)
  • Spent 3 hours trying to debug why the synchronizer wasn't working and realised a silly .each was missing :D
  • built the perform_sync that uploads only files that don't exist in Dropbox to avoid duplication
  • started to read a tutorial on how to build a gem suggested by our amazing coach @rojo and got an overview of a gem by super @robin at Absolventa
  • learnt about intersection and difference working with arrays


  • read the PRY documentation
  • updated our plugins and pulled from github
  • looked through the dropbox plugin and why it seemed not do do the actual backup
  • added a method that removes the files from the drive account, that are not in the local backup files anymore


You must be logged in to add a comment.