Загружаю картинку вот так
def get_photo():
upload = requests.post(vk.photos.getMessagesUploadServer()['upload_url'], files={'photo': open(os.path.join(DIR, random.choice(os.listdir(DIR))), 'rb')}).json()
get = vk.photos.saveMessagesPhoto(photo=upload['photo'], server=upload['server'], hash=upload['hash'])[0]
photo = "photo{}_{}".format(get["owner_id"], get["id"])
print(photo)
return photo
Отправляю так
def create_comment_photo(atch):
vk.wall.createComment(owner_id=int(data[0]), post_id=int(data[1]), attachments=atch)
if funct == 2:
for comments in range(msg_count):
create_comment_photo(get_photo())
msg_num += 1
print(f'Комментарий {msg_num} отправлен')
time.sleep(2.2)
В логах все норм