Skip to content

Handle MEDIA_CAPTION_TOO_LONG error #14

@ableev

Description

@ableev

Originally reported in #9.

The problem: telegram bot api doesn't allow to add caption to the photo with length more than 200 symbols.

Current solution: message cuts to 200 symbols, warning to stdout, unable to get truncated part of message.

To discuss two ideas:

  1. Split message in two parts: first one is the caption and has 200 symbols length, second one is the next part, sent after the first as plain text without graph.
  2. Separate text and image if length is more than 200 symbols. The first message is graph, the second is plain text (or we can swap them).

What is best? Or any other ideas?

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions