Commit graph

105 commits

Author SHA1 Message Date
Maybe Waffle
ceb2415351 Require that UpdateListener::StopToken is Send 2022-03-27 13:29:17 +04:00
Waffle Maybe
85287ffad3
Update CHANGELOG.md 2022-03-23 10:47:56 +04:00
Hirrolot
7aa0439afd Release v0.7.2 2022-03-22 11:40:53 +06:00
Waffle Maybe
a4c147538b
Merge pull request #559 from teloxide/deprecate_enable_logging
Deprecate `enable_logging!` in favour of configuring logging yourself
2022-03-21 21:12:04 +04:00
Waffle Maybe
29415a6d87
Update CHANGELOG.md
Co-authored-by: Hirrolot <hirrolot@gmail.com>
2022-03-21 19:31:44 +04:00
Hirrolot
1f95c1d2b3 Don't warn abount unhandled updates in repls2 2022-03-21 21:11:46 +06:00
Maybe Waffle
dbc7633fdb Deprecate enable_logging! in favour of configuring logging yourself 2022-03-21 18:55:34 +04:00
Hirrolot
81fbb1769c
Merge pull request #558 from teloxide/log-dispatcher-error
Log `UpdateKind::Error` in `dispatching2`
2022-03-21 07:48:38 -07:00
Hirrolot
91f8eb6acc Log UpdateKind::Error in dispatching2 2022-03-21 20:40:04 +06:00
Hirrolot
7a7667fff9 Changelogify ?Sized in HandlerExt::enter_dialogue 2022-03-21 20:09:06 +06:00
Hirrolot
cf8c1b78b7 Rewrite examples/db_remember.rs to use ErasedStorage 2022-03-21 20:06:32 +06:00
Hirrolot
0b6e7acf9f Favour a default function instead of StorageExt 2022-03-21 18:09:36 +06:00
Hirrolot
c6f0cd9404 Implement ErasedStorage 2022-03-20 09:06:21 +06:00
Hirrolot
3ad74b6a9b Release v0.7.1 2022-03-09 20:42:12 +06:00
Maybe Waffle
31ff3a468d Fix compilation with non-default features 2022-03-08 12:20:01 +04:00
Hirrolot
f923114d20
Fix the changelog 2022-02-09 17:06:17 +06:00
Hirrolot
30d37741e4 Release v0.7.0 2022-02-09 08:38:57 +06:00
Hirrolot
62da2cacb8 Update the changelog 2022-02-07 15:58:34 +06:00
Maybe Waffle
675600bf74 Fix docs.rs build 2022-02-06 17:23:21 +03:00
Hirrolot
25db911829
Update the v0.6.0 release date 2022-02-06 18:33:01 +06:00
Hirrolot
9eac077ecd Release v0.6.0 2022-02-06 17:47:56 +06:00
Hirrolot
c0c18ebbdf Mention teloxide-core in the changelog 2022-02-06 17:32:30 +06:00
Hirrolot
672e879ffe Update CHANGELOG.md 2022-02-05 13:50:46 +06:00
Hirrolot
07b844db99 Add BotCommand::bot_commands 2022-02-05 02:18:47 +06:00
Hirrolot
735e6a41f2 Replace CARGO_PKG_NAME with CARGO_CRATE_NAME in logging 2022-02-05 01:07:28 +06:00
Maybe Waffle
a7182962f7 Fix polling's StopToken not being Send 2022-01-18 21:01:47 +03:00
Maybe Waffle
993e6e53aa Do not retry get_updates infinitely while stopping polling listener 2022-01-17 14:42:49 +03:00
Waffle Maybe
fb238ff656
Merge branch 'dev' into master-to-dev-1 2021-10-25 17:17:42 +03:00
Hirrolot
178937f9d7
Fix the patch release number (0.5.2 => 0.5.3) 2021-10-25 20:10:12 +06:00
Maybe Waffle
f31adc1bb2 Dump version (0.5.2 -> 0.5.3) 2021-10-25 15:52:57 +03:00
­
964323fca4
Fix compilation without ctrlc_handler feature
The feature gate is moved to the `dispatching` mod level.
Public exports are also covered by this flag now.
2021-10-25 02:12:11 +03:00
Waffle
a97050de24 Require that AsUpdateStream::Stream is Send 2021-09-04 14:05:18 +03:00
Waffle Lapkin
38c3d6e119
Remove square brackets from changelog 2021-08-31 18:38:21 +03:00
Hirrolot
2a6067fe94 Prepare for v0.5.2 2021-08-25 23:51:19 +06:00
Waffle
5e260d0afc Depend on a right futures version 2021-08-25 18:12:14 +03:00
Hirrolot
2ae7c10fc7 Update the v0.5.1 release date 2021-08-05 23:10:40 +06:00
Hirrolot
a35667ac2b Prepare for v0.5.1 2021-08-01 20:45:59 +06:00
Waffle
b984464a79 Improve log messages when ^C is received with ^C handler setted up
Now they tell the user to not repeatedly press `^C` since only the first
signal actually does anything, all subsequesnt ones are ignored.
2021-07-21 15:53:52 +03:00
Hirrolot
674b1f974a Prepare for v0.5.0 2021-07-08 15:22:13 +06:00
Waffle
369e43aa7e Update dependencies 2021-07-05 21:29:36 +03:00
Waffle Lapkin
f69abcc938
Update CHANGELOG.md 2021-07-04 10:29:46 +03:00
dracarys18
1f1a3abd6b utils: Change the user_id type to i64
user_id is of type i64 in User struct (bd104a0a08/src/types/user.rs (L10))

Signed-off-by: dracarys18 <karthihegde010@gmail.com>
2021-07-03 17:31:57 +05:30
Kartikeya Hegde
0a89f46702
Update CHANGELOG.md
Co-authored-by: Hirrolot <hirrolot@gmail.com>
2021-06-30 19:47:43 +05:30
dracarys18
9476636d73 Update changelog 2021-06-30 19:44:12 +05:30
Waffle
faef0c6ffb Implement automatic update filtering
Add `UpdateListener::hint_allowed_updates` and `StatefulListener::hint_allowed_updates`.

Make `Dispatcher` call `UpdateListener::hint_allowed_updates` when starting dispatching.
2021-06-27 15:07:21 +03:00
Hirrolot
a6c480930a Print info about graceful shutdown to users 2021-06-27 15:44:46 +06:00
Waffle
8796bc11ba Update changelog 2021-06-27 11:04:55 +03:00
Waffle
f0de55ad55 Add Dispatcher::setup_ctrlc_handler function.
This function sets up `^C` handler which shuts down dispatching.
2021-06-25 16:57:24 +03:00
Waffle
41a95079b2 Add Dispatcher::shutdown function
This function allows to gracefuly shutdown dispatching.
2021-06-25 16:57:24 +03:00
Waffle
aeca45a579 Refactor UpdateListner trait
Instead of `Stream` super trait we now require `for<'a> AsUpdateStream<'a, E'>`
as a super trait. `AsUpdateStream` in turn provides `as_stream` function which
takes `&mut self` and returns `Self::Stream` (the trait is needed to workaround
lack of GAT).

This patch also adds a `stop` function that allows stopping the listener.

Since `UpdateListner` now isn't `Stream` and required methods, it's blanked
implementation for streams was removed.

`polling` and `polling_default` functions now also require `R: 'static`.
2021-06-25 16:57:24 +03:00