response = client.get_object(Bucket=bucket,Key=key)
logger.info("response: {}" .format(response))
#to read the gzip file into table format
df=pd.read_table(io.BytesIO(response['Body'].read()),encoding='utf-8',header=1,low_memory=False, sep='|' ,compression='gzip')
logger.info("data in file {}" . format(df))
#to get the first 5 lines from dataframe -->df
df.head()
错误:
在完成请求之前退出流程