rubenlagus / TelegramBots

Java library to create bots using Telegram Bots API
https://telegram.me/JavaBotsApi
MIT License
4.69k stars 1.19k forks source link

java.lang.NoSuchMethodError: 'java.util.Map org.eclipse.jetty.http.MimeTypes.getInferredEncodings()' #1383

Open wood20230311 opened 3 months ago

wood20230311 commented 3 months ago

Describe the bug when I use telegramBot by 7.4.1 and my jdk version is 17,when I new a TelegramBotsWebhookApplication object and registerBot,I get this exception.

How to reslove this problem? I think this is current telegram version is not support for jdk 17?

my pom.xml like this

17 7.4.1 org.telegram telegrambots-longpolling ${telegrambots.version}
    <dependency>
        <groupId>org.telegram</groupId>
        <artifactId>telegrambots-webhook</artifactId>
        <version>${telegrambots.version}</version>
    </dependency>
    <dependency>
        <groupId>org.telegram</groupId>
        <artifactId>telegrambots-client</artifactId>
        <version>${telegrambots.version}</version>
    </dependency>
    <dependency>
        <groupId>org.telegram</groupId>
        <artifactId>telegrambots-extensions</artifactId>
        <version>${telegrambots.version}</version>
    </dependency>