def get_contents(self): if not settings.AWS_ENABLED: try: return open(self.local_filename).read() except IOError: return '' else: return s3.read_file('source', self.s3_path)
def read_build_log(self): if not settings.AWS_ENABLED: with open(self.build_log, 'r') as f: return f.read() else: return s3.read_file('builds', self.build_log)
def read_build_log(self): if not settings.AWS_ENABLED: with open(self.build_log, 'w') as f: return f.read() else: return s3.read_file('builds', self.build_log)
def get_contents(self): if not settings.AWS_ENABLED: return self._get_contents_local() else: return s3.read_file(self.bucket_name, self.s3_path)
def read_build_log(self): return s3.read_file('builds', self.build_log)