Closed zsanzharko closed 1 year ago
are you sure that classpath contain starter?
@centralhardware Are you mean about gradle dependencies? This is my dep.
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
implementation 'org.springframework.boot:spring-boot-starter-jdbc'
compileOnly 'org.projectlombok:lombok'
implementation 'org.postgresql:postgresql'
annotationProcessor 'org.springframework.boot:spring-boot-configuration-processor'
annotationProcessor 'org.projectlombok:lombok'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
implementation 'org.telegram:telegrambots-spring-boot-starter:6.5.0'
}
I have same problem, but I fixed that after created annotation:
And use it with MainApplicationClass
@rubenlagus What do you think?
@Aryesia but its not help, i create extend TelegramLongPollingBot and add EnableTelegramBot to application and no print update
@Programistich Hmm.. It's working for me. Maybe you have another problem (Proofs in screenshots)
Can u share this project?
And no one updates print
if i register manual i have error
DefaultBotSession : Error executing org.telegram.telegrambots.meta.api.methods.updates.GetUpdates query: [409] Conflict: terminated by other getUpdates request; make sure that only one bot instance is running
Running with:
Spring Boot v3.1.0 Spring v6.0.9 Java 20.0.1 Gradle-8.1.1
plugins {
id 'java'
id 'org.springframework.boot' version '3.1.0'
id 'io.spring.dependency-management' version '1.1.0'
}
group = 'group'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = '17'
configurations {
compileOnly {
extendsFrom annotationProcessor
}
}
repositories {
mavenCentral()
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter'
compileOnly 'org.projectlombok:lombok'
implementation 'org.telegram:telegrambots:6.7.0'
implementation 'org.telegram:telegrambots-spring-boot-starter:6.7.0'
implementation 'org.telegram:telegrambotsextensions:6.7.0'
developmentOnly 'org.springframework.boot:spring-boot-devtools'
annotationProcessor 'org.springframework.boot:spring-boot-configuration-processor'
annotationProcessor 'org.projectlombok:lombok'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
}
tasks.named('test') {
useJUnitPlatform()
}
@Import({TelegramBotStarterConfiguration.class})
@SpringBootApplication
public class TelegramBotApplication {
public static void main(String[] args) {
SpringApplication.run(TelegramBotApplication.class, args);
}
}
works fine
Now latest version for telegram is 2.7.12
https://github.com/rubenlagus/TelegramBots/commit/a48c4b2b94c550597a77e70205a284ac9dd7ec07
Describe the bug Hi! I can't see when telegram bot is running in spring. He's just start and stoping.
Code
LOG
Information