rubenlagus / TelegramBots

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

What about Java9+? #480

Open bvn13 opened 6 years ago

bvn13 commented 6 years ago

Have an error: module 'my-module' reads package 'org.telegram.telegrambots' from both 'telegrambots' and 'telegrambots.meta'.

Seems it need to reneme sub-projects' packages like org.telegram.telegrambotsmeta or place it into one project (worse).

rubenlagus commented 6 years ago

Java9 is, according to Oracle a short term release, quite probably I'll update to Java10 directly at some point in the future. Not planned at the moment.

ChmilevFA commented 6 years ago

I have the same issue for the Java 10 Do we have any ways to use TelegramBots with Java 9+?

ChmilevFA commented 6 years ago

A bit more details:

module 'your.module' reads package 'org.telegram.telegrambots' from both 'telegrambots' and 'telegrambots.meta'.

Seems like it is impossible to use the same package name from different modules with Java's module system. https://stackoverflow.com/questions/40985153/with-java-9-modules-will-multiple-modules-be-able-to-export-the-same-package

Besides the above mentioned problem with using the same package name for different modules seems bad practice just because you must know which classes you have in another modules not to intersect names for them.

rubenlagus commented 6 years ago

@bvn13 @ChmilevFA Can we close this issue with last release?

bvn13 commented 6 years ago

@rubenlagus not checked yet