| | |
| | | import datetime |
| | | import json |
| | | import traceback |
| | | from typing import List, Tuple |
| | |
| | | for comment in comments.get('data', {}).get('comments'): |
| | | self.logger.debug( |
| | | f'{aweme.video_id},{aweme.tenant_id},{aweme.task_id},{aweme.task_name},{aweme.platform},{comment.get("content")}') |
| | | if publish_type == 0: |
| | | self.change_status(aweme=aweme) |
| | | return |
| | | if (datetime.datetime.now() - datetime.datetime.fromtimestamp( |
| | | comment.get('create_time')/1000)).days >= int(publish_type): |
| | | self.change_status(aweme=aweme) |
| | | return |
| | | yield { |
| | | 'aweme': aweme, |
| | | 'comment': comment, |