See :meth:`telegram.TelegramObject.de_json`. The :paramref:`media` field will not be included for deserialization. .. deprecated:: 22.8 This class is input only and will be removed in the next version.
(cls, data: JSONDict, bot: "Bot | None" = None)
| 237 | # tags: deprecated 22.8 |
| 238 | @classmethod |
| 239 | def de_json(cls, data: JSONDict, bot: "Bot | None" = None) -> "InputPollOption": |
| 240 | """See :meth:`telegram.TelegramObject.de_json`. The :paramref:`media` field will |
| 241 | not be included for deserialization. |
| 242 | |
| 243 | .. deprecated:: 22.8 |
| 244 | This class is input only and will be removed in the next version. |
| 245 | """ |
| 246 | warn( |
| 247 | PTBDeprecationWarning( |
| 248 | "22.8", |
| 249 | "`InputPollOption.de_json` is deprecated. This class is input only and will be " |
| 250 | "removed in the next version. The `media` field will not be included for " |
| 251 | "deserialization.", |
| 252 | ), |
| 253 | stacklevel=2, |
| 254 | ) |
| 255 | data = cls._parse_data(data) |
| 256 | |
| 257 | data["text_entities"] = de_list_optional(data.get("text_entities"), MessageEntity, bot) |
| 258 | |
| 259 | return super().de_json(data=data, bot=bot) |
| 260 | |
| 261 | |
| 262 | class PollOption(TelegramObject): |
nothing calls this directly
no test coverage detected