mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-15 01:32:20 -05:00
- brings boto S3 into new AWS folder - CSV processing utils method Rejigs the jobs rest endpoint - removes some now unused endpoints, Calls to the task with the job, job processing in task, delegating SMS calls to the sms task
8 lines
205 B
Python
8 lines
205 B
Python
from boto3 import resource
|
|
|
|
|
|
def get_job_from_s3(bucket_name, job_id):
|
|
s3 = resource('s3')
|
|
key = s3.Object(bucket_name, '{}.csv'.format(job_id))
|
|
return key.get()['Body'].read().decode('utf-8')
|