telegram-notifications-plugin
telegram-notifications-plugin copied to clipboard
FIXED c.f.j.c.JsonParseException: Numeric value out of range of int
I'm not Java developer, so this pull request is more like an example.
Problem: My UserId no longer fits into Int
2021-12-27 15:21:18.778+0000 [id=89] SEVERE o.t.t.meta.logging.BotLogger#severe: BOTSESSION
com.fasterxml.jackson.core.JsonParseException: Numeric value (********) out of range of int
at [Source: (String)"{"ok":true,"result":[{"update_id":26962324,
"message":{"message_id":71,"from":{"id":********,"is_bot":false,"first_name":"********","language_code":"ru"},"chat":{"id":********,"first_name":"********","type":"private"},"date":1640586660,"text":"/start","entities":[{"offset":0,"length":6,"type":"bot_command"}]}},{"update_id":26962325,
"message":{"message_id":72,"from":{"id":********,"is_bot":false,"first_name":"********","language_code":"ru"},"chat":{"id":********,"first_name":"********","type":"private"}"[truncated 1526 chars]; line: 2, column: 51]
at com.fasterxml.jackson.core.JsonParser._constructError(JsonParser.java:1804)
at com.fasterxml.jackson.core.base.ParserMinimalBase._reportError(ParserMinimalBase.java:693)
................................................
It is fixed in the version TelegramBots API 5.1: https://github.com/rubenlagus/TelegramBots/commit/6653ffe9379bac874bbdff63e011f2c825555494#diff-2d34b08ac04313d2bb1afd92284a4146936a365ae6c8f8a614523420fdcf1848
I laid out the changes in this pull request with which the plugin was compiled and worked.