Skip to content

[BUG] AttributeError: 'File' object has no attribute 'download_to_drive' #4159

@Sp4g0

Description

@Sp4g0

Steps to Reproduce

voice_id = message.voice.file_id
new_file = bot.get_file(voice_id)
new_file.download_to_drive()

Expected behaviour

download voice message

Actual behaviour

can't download voice message

Operating System

windows

Version of Python, python-telegram-bot & dependencies

python-telegram-bot 21.0.1
Bot API 7.1
Python 3.11.8 (tags/v3.11.8:db85d51, Feb  6 2024, 22:03:32) [MSC v.1937 64 bit (AMD64)]

Relevant log output

No response

Additional Context

method download was deprecated from version 20

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions