code: def read_from_file(self, filename):
          
          if not exists(filename):
              return -1
          with open(filename) as fd:
              needs_json = fd.read()
              try:
                  minimum_needs = json.loads(needs_json)
              except (TypeError, ValueError):
                  minimum_needs = None
  
          if not minimum_needs:
              return -1
  
          return self.update_minimum_needs(minimum_needs)
docs: Read from an existing json file.
  
          :param filename: The file to be written to.
          :type filename: basestring, str
  
          :returns: Success status. -1 for unsuccessful 0 for success
          :rtype: int