noXplode / aiogram_calendar

Date Selection tool & Inline calendar for Aiogram telegram bots
MIT License
151 stars 36 forks source link

This is not works with aiogram 3 #5

Closed lev007-ops closed 9 months ago

lev007-ops commented 2 years ago

This is not works with aiogram 3, how to fix it?

noXplode commented 2 years ago

was not using v3 yet, will check this week

noXplode commented 1 year ago

@lev007-ops checked v3, its not backwards compatible to v2, a lot of changes to classes, both calendars & example must be changed for v3 I`ll create v3 version, but have no estimations when

lev007-ops commented 1 year ago

@noXplode, хорошо

lev007-ops commented 1 year ago

@noXplode, Okay. I hope it will be fast. It's just that my telegram bot works with your calendar and I transfer it to aiogram 3x

lev007-ops commented 1 year ago

@noXplode,Hi. Have you tried transferring it to aiogram 3?

o-murphy commented 1 year ago

@noXplode,Hi. Have you tried transferring it to aiogram 3?

I made a fork for aiogram 3

Instalation

pip install aiogram3_calendar Repository is here

o-murphy commented 1 year ago

@noXplode, хорошо

You can create another branch for aiogram 3 from you master branch and after you can make pull request from my fork, so you'll have versions compatible with aiogram 2 and aiogram 3 in the same time. Also you can clone my repo to your master branch and made validation in you init.py file to import required version automaticaly

lev007-ops commented 1 year ago

Hello, thanks

ghost commented 1 year ago

HJello! Try to use :

@disp.callback_query_handler(simple_cal_callback.filter()) async def process_simple_calendar(query: CallbackQuery, data: dict): selected, date = await SimpleCalendar().process_selection(query=query, data=data ) if selected: await query.message.answer( f"Вы выбрали: {date.strftime('%d.%m.%Y')}", reply_markup=ReplyKeyboardRemove() ) process_simple_calendar never handle the calendar. What I'm doing wrong?

fluffur commented 1 year ago

I also made a fork for aiogram 3.0.0b7 (3.0.0b8)

pip install aiogram3b8-calendar

noXplode commented 9 months ago

upgraded to aiogram v3, also added some new features - today & cancel button, overridable labels (allows translation to any language)