Commit graph

935 commits

Author SHA1 Message Date
Temirkhan Myrzamadi
4b0dea21f1 Hot fixes 2020-02-11 19:12:14 +06:00
Temirkhan Myrzamadi
0ae2d975df Add the state! macro 2020-02-11 04:04:57 +06:00
Temirkhan Myrzamadi
4a7c31fec7 Use Arc<Bot> instead of BotWrapper 2020-02-11 03:46:33 +06:00
Temirkhan Myrzamadi
9525414f8d Simplify examples/simple_dialogue 2020-02-11 03:13:09 +06:00
Temirkhan Myrzamadi
bde4d09e5d Add dialogue::{next, exit} 2020-02-11 02:54:08 +06:00
Temirkhan Myrzamadi
809aaef9b1 Winning the compiler... 2020-02-10 00:29:30 +06:00
Temirkhan Myrzamadi
fbd02c5a14 Trying to win the compiler 2020-02-08 22:59:57 +06:00
Temirkhan Myrzamadi
e6bf25b3bf Rework handlers (failing now) 2020-02-08 00:06:41 +06:00
Temirkhan Myrzamadi
ab8dae9213 Fix Clippy 2020-02-07 20:45:00 +06:00
Temirkhan Myrzamadi
99c7bf5955
Merge branch 'dev' into rework-dispatching 2020-02-07 20:31:52 +06:00
Temirkhan Myrzamadi
2785c892c0 Extend the middlewares API 2020-02-07 06:20:14 +06:00
Temirkhan Myrzamadi
d4170725aa Fix the docs 2020-02-07 06:03:33 +06:00
p0lunin
375f09df18 added fields to Poll 2020-02-05 17:02:10 +02:00
p0lunin
4d8b2d0473 added field language for MessageEntity 2020-02-04 23:19:06 +02:00
p0lunin
a95bb5b2d9 added struct Me 2020-02-04 23:13:31 +02:00
p0lunin
95b190e573 added new type poll_answer 2020-02-04 23:06:36 +02:00
p0lunin
357e2640f4 added new type keyboard_button_poll_type.rs 2020-02-04 22:59:44 +02:00
p0lunin
fb3f0558c2 added new fields to sendPoll 2020-02-04 22:44:41 +02:00
p0lunin
b064b85d37 fixed test (but it still failed, help please) 2020-02-04 20:47:29 +02:00
p0lunin
6bb8241f27 fix merged 2020-02-04 20:21:41 +02:00
p0lunin
21328c152c Merge remote-tracking branch 'origin/rework-dispatching' into rework-dispatching
# Conflicts:
#	src/dispatching/dispatcher_handler_ctx.rs
2020-02-04 20:19:10 +02:00
p0lunin
327be5811c added functions into DispatcherHandlerCtx<Message> 2020-02-04 20:17:07 +02:00
Temirkhan Myrzamadi
32f44f83ab A quick fix 2020-02-04 21:39:42 +06:00
Temirkhan Myrzamadi
17de4840d7 Refactor 2020-02-04 21:38:25 +06:00
p0lunin
5e8a698d22 Merge branch 'dev' of https://github.com/teloxide/teloxide into rework-dispatching
 Conflicts:
	src/utils/mod.rs
2020-02-04 14:22:30 +02:00
p0lunin
ca360aa1f4 added functions to DispatcherHandlerCtx 2020-02-03 15:26:09 +02:00
Temirkhan Myrzamadi
0077b99ef6
Merge branch 'dev' into useful_functions 2020-02-03 17:14:59 +06:00
Temirkhan Myrzamadi
cea09a030a Fix the docs 2020-02-03 17:13:26 +06:00
Temirkhan Myrzamadi
7e34007a4d Divide AsyncHandler into different traits 2020-02-03 16:25:05 +06:00
Temirkhan Myrzamadi
ee3a95b31e Yet another fix 2020-02-03 03:15:55 +06:00
Temirkhan Myrzamadi
16aca0f0f8 Quick fix of the docs 2020-02-03 03:06:31 +06:00
Temirkhan Myrzamadi
a7dee4cab5 Improve the docs of teloxide::dispatching 2020-02-03 03:03:28 +06:00
Temirkhan Myrzamadi
32cab96af5 Fix the docs 2020-02-03 01:42:32 +06:00
Temirkhan Myrzamadi
b7b6cd988c Reduce the Dispatcher::dispatch_with_listener complexity 2020-02-03 01:32:01 +06:00
p0lunin
5dafe892ac added function handle<T> in dispatcher 2020-02-02 21:22:58 +02:00
Temirkhan Myrzamadi
32d607daa9 Fix ping-pong-bot 2020-02-03 01:12:36 +06:00
Temirkhan Myrzamadi
2c4102e2b3 Simplify building ReplyKeyboardMarkup 2020-02-03 00:54:11 +06:00
Temirkhan Myrzamadi
61d002b8d4 Refactor 2020-02-02 22:32:27 +06:00
Temirkhan Myrzamadi
d7d97ef136 Fix the docs 2020-02-02 22:03:18 +06:00
Temirkhan Myrzamadi
43a0a81d78 Rename handler.rs -> async_handler.rs 2020-02-02 21:16:23 +06:00
p0lunin
b0b9ad6204 deleted IDE files 2020-02-01 21:42:25 +02:00
p0lunin
8b90581927 added documentation 2020-02-01 21:40:17 +02:00
p0lunin
0308f8950a add #[command(description = "")] for enums 2020-02-01 21:36:56 +02:00
p0lunin
4d4970f450 fix compilation error 2020-02-01 21:07:13 +02:00
Temirkhan Myrzamadi
1a6297747c Add examples/simple_fsm 2020-01-30 04:54:40 +06:00
Temirkhan Myrzamadi
c98b53b9a8 Impl AsyncHandler for SessionDispatcher 2020-01-30 01:10:02 +06:00
Temirkhan Myrzamadi
1d6a21acb0 Add teloxide::prelude 2020-01-30 00:11:52 +06:00
Temirkhan Myrzamadi
6f2abd10ef Finally fix the error 2020-01-29 23:43:47 +06:00
p0lunin
92ccb49216 Merge remote-tracking branch 'origin/useful_functions' into useful_functions 2020-01-29 19:26:13 +02:00
p0lunin
1cec80bf9d add Update::user(), Update::chat() functions 2020-01-29 19:25:56 +02:00
Temirkhan Myrzamadi
27ae3e13cf Trying to fix ping_pong_bot.rs 2020-01-29 21:08:18 +06:00
Temirkhan Myrzamadi
3bad400c03 Fix the error 2020-01-29 20:48:57 +06:00
Temirkhan Myrzamadi
84d4e6fb2c Rework teloxide::dispatching (fails now) 2020-01-29 10:47:17 +06:00
Temirkhan Myrzamadi
017a0d3169 Remove parse_command_into_enum and fix the docs 2020-01-28 08:34:10 +06:00
Temirkhan Myrzamadi
9971659e03 Merge branch 'useful_functions' of https://github.com/teloxide/teloxide into useful_functions 2020-01-28 08:26:00 +06:00
p0lunin
2028ce70c7 add BotCommand::parse(s: &str) 2020-01-26 23:13:29 +02:00
Temirkhan Myrzamadi
b71088746c Bullshit 2020-01-26 04:18:13 +06:00
Temirkhan Myrzamadi
004d5bdaf5 Fix the docs (utils/parsers.rs) 2020-01-26 04:14:47 +06:00
p0lunin
77487c07dd fix clippy errors 2020-01-25 23:34:17 +02:00
p0lunin
0654bbc82d now rename in variant overlap rename in enum 2020-01-25 22:47:31 +02:00
Temirkhan Myrzamadi
9ae647f6f9 Merge branch 'improve-requests' of https://github.com/teloxide/teloxide into improve-requests 2020-01-25 01:00:17 +06:00
Temirkhan Myrzamadi
47bbd9675e Compare tokens in BotWrapper::eq 2020-01-25 00:59:49 +06:00
Temirkhan Myrzamadi
e17a4cedd0 Move BotWrapper into bot_wrapper.rs 2020-01-25 00:58:36 +06:00
p0lunin
d490ed9bc0 replace return type in url() function to Url from String 2020-01-24 20:12:23 +02:00
p0lunin
9cefbca3f0 rename TelegramBotCommand to BotCommand 2020-01-24 19:47:10 +02:00
p0lunin
04852ddd22 add attributes for enums 2020-01-24 19:44:20 +02:00
p0lunin
73be83a5b1 add support for many arguments in one attribute like #[command(attr1 = "value1", attr2 = "value2")] 2020-01-24 11:55:20 +02:00
Temirkhan Myrzamadi
f9d83832f3
Merge branch 'dev' into improve-requests 2020-01-24 07:16:21 +06:00
Temirkhan Myrzamadi
a8e1dac7bb Add docs to Bot 2020-01-24 07:12:01 +06:00
p0lunin
34e1e69e77 refactor teloxide-macros, and added attributes prefix and description 2020-01-23 23:20:59 +02:00
p0lunin
8c2b0b6c70 fmt another 2020-01-23 23:19:54 +02:00
Temirkhan Myrzamadi
0232108822 Don't clone a bot while cloning a request 2020-01-24 01:24:09 +06:00
Temirkhan Myrzamadi
b27138163c Rename 'network' to 'net'
Like std::net
2020-01-22 07:04:17 +06:00
Temirkhan Myrzamadi
05c27aa9d0 Fix rustfmt 2020-01-22 01:56:00 +06:00
Temirkhan Myrzamadi
6c1a39570c Fix Clippy 2020-01-22 01:54:05 +06:00
Temirkhan Myrzamadi
6a1d715a69 Small fixes 2020-01-22 01:51:24 +06:00
Temirkhan Myrzamadi
9cd11d02d7 Fix the docs of the rest of requests 2020-01-22 01:41:32 +06:00
p0lunin
841f80ea78 merge from dev 2020-01-21 10:44:41 +02:00
p0lunin
f6777f80a9 Merge branch 'dev' of https://github.com/teloxide/teloxide into filters
 Conflicts:
	src/dispatching/mod.rs
2020-01-21 10:43:10 +02:00
p0lunin
9c020a23cb remove feature regex-filter 2020-01-21 10:42:43 +02:00
p0lunin
4db07fc189 delete filters 2020-01-21 10:41:10 +02:00
Temirkhan Myrzamadi
81167ff44d Fix the docs of several requests 2020-01-21 01:03:03 +06:00
p0lunin
1aae70048e added is_{private, group, supergroup, channel, chat} for type Chat 2020-01-19 16:05:45 +02:00
p0lunin
50c29227ce Merge branch 'dev' of https://github.com/teloxide/teloxide into useful_functions 2020-01-19 15:50:25 +02:00
p0lunin
5f34d7ffc6 changed name of trait from TelegramCommandEnum to TelegramBotCommand and divided parse_command into parse_command and parse_command_with_prefix 2020-01-19 15:48:02 +02:00
p0lunin
4af7b9f1f0 Fix bug with last_name, now between first_name and last_name is space 2020-01-19 15:46:11 +02:00
p0lunin
db5145911b added parse_command, TelegramCommandEnum trait, parse_command_into_enum 2020-01-18 15:14:31 +02:00
Temirkhan Myrzamadi
e3235adf2f Fix UpdateKind 2020-01-18 05:40:01 +06:00
Temirkhan Myrzamadi
9712366d4a Merge branch 'dev' of https://github.com/teloxide/teloxide into dev 2020-01-17 20:57:53 +06:00
Temirkhan Myrzamadi
3b6dbecd11 Fix conflicts 2020-01-17 20:57:26 +06:00
Temirkhan Myrzamadi
c0f83a4999 Fmt 2020-01-17 20:19:13 +06:00
p0lunin
583d021be7 update docs for CommandFilter 2020-01-17 15:36:22 +02:00
p0lunin
eb430b0487 docs for CommandFilter 2020-01-17 15:35:30 +02:00
p0lunin
c3c9b92f87 change position of arguments to more readable 2020-01-17 15:35:07 +02:00
p0lunin
5f16c7b9ff fmt 2020-01-17 15:24:54 +02:00
p0lunin
3e983a804c fix wrong return type RegexFilter::test 2020-01-17 15:24:29 +02:00
p0lunin
c3d90abe7d added RegexFilter 2020-01-17 14:54:51 +02:00
p0lunin
2bd67ff0b3 fixed command_filter 2020-01-16 13:02:53 +02:00
p0lunin
6a6e49d60a added method user_mention_or_link 2020-01-16 12:25:52 +02:00
p0lunin
c94c502ddd removed unused imports 2020-01-16 12:25:33 +02:00
Temirkhan Myrzamadi
dedc861523 Implement chat::Dispatcher 2020-01-15 03:46:22 +06:00
p0lunin
52d47f54be functions for Message and User 2020-01-14 22:03:34 +02:00
p0lunin
1ec4e2d400 fixes 2020-01-14 21:17:02 +02:00
p0lunin
7755e09122 remove .to_string() 2020-01-14 20:58:38 +02:00
p0lunin
814a424caa
make method text_from public 2020-01-13 13:07:19 +02:00
p0lunin
5cb48d8a3f add method text_from 2020-01-12 21:23:04 +02:00
Temirkhan Myrzamadi
214969685a
Merge pull request #136 from teloxide/passport-errors
Add passport_element_error.rs
2020-01-12 23:01:21 +06:00
Temirkhan Myrzamadi
60d84b817c Add passport_element_error.rs 2020-01-12 21:44:54 +06:00
Temirkhan Myrzamadi
7e02337ebe
Merge pull request #135 from teloxide/checked_types
Checked types
2020-01-12 02:35:03 +06:00
p0lunin
629fcaf564 fmt 2020-01-11 21:47:59 +02:00
p0lunin
1d6803a65f fix 2020-01-11 21:46:30 +02:00
p0lunin
d1eedece40 mime 2020-01-11 21:46:13 +02:00
Temirkhan Myrzamadi
fbc6b57e2b Replace ” with ` 2020-01-12 01:17:49 +06:00
p0lunin
d312a24f12 use serde::{Serialize, Deserialize} 2020-01-11 21:00:52 +02:00
p0lunin
7c82f7e423 update test 2020-01-11 20:58:43 +02:00
p0lunin
d50e47ecd2 languageCode 2020-01-11 20:56:49 +02:00
p0lunin
3e0b647658 CountryCode 2020-01-11 20:48:28 +02:00
Temirkhan Myrzamadi
5fd6ae3630 Fix the docs 2020-01-11 21:04:57 +06:00
Sergey Levitin
1ac66eed9e Merge branch 'dev' of github.com:teloxide/teloxide into session-dispatcher 2020-01-11 16:06:57 +03:00
Temirkhan Myrzamadi
d247320a76 Update the docs 2020-01-10 20:49:17 +06:00
p0lunin
21ea73eafd SuccessfulPayment::currency type switch to Currency 2020-01-10 12:27:30 +02:00
p0lunin
80a9ebebd2 fmt 2020-01-10 12:26:48 +02:00
p0lunin
1a8f012de4 derive_more 2020-01-10 12:24:31 +02:00
p0lunin
cadd781abf add enum Currency 2020-01-09 21:17:47 +02:00
p0lunin
c7fb8da774 fix wrong name 2020-01-09 21:04:05 +02:00
p0lunin
afa877ff56 add implementation From for ReplyMarkup 2020-01-09 21:00:25 +02:00
p0lunin
c2fb937763 rename variants ReplyMarkup 2020-01-09 20:59:59 +02:00
p0lunin
1743c24026 fix double serialization 2020-01-09 20:35:10 +02:00
Temirkhan Myrzamadi
3351838a36 Write the docs 2020-01-08 17:59:30 +06:00
Temirkhan Myrzamadi
1547034741 Rename the generics 2020-01-08 16:51:10 +06:00
Temirkhan Myrzamadi
95a540aa19 Fix the CI 2020-01-08 16:38:48 +06:00
Temirkhan Myrzamadi
e431689ee9 Merge branch 'dev' of https://github.com/teloxide/teloxide into dev 2020-01-08 16:30:04 +06:00
Temirkhan Myrzamadi
9189eb1aaa
Merge pull request #129 from teloxide/error-kind
Error kind
2020-01-08 16:29:29 +06:00
Temirkhan Myrzamadi
cf727033d7 Quick fixes 2020-01-08 16:24:52 +06:00
Temirkhan Myrzamadi
54571dc720 Fix the docs 2020-01-08 16:15:29 +06:00
Temirkhan Myrzamadi
66177e9de3 Rename OtherKind -> Other 2020-01-08 16:00:18 +06:00
Temirkhan Myrzamadi
c8a1bdce25 Create dispatching::private 2020-01-08 04:33:22 +06:00
p0lunin
823a92a303 add deserialize ApiErrorKind 2020-01-08 00:19:32 +02:00
Temirkhan Myrzamadi
7eac9961be Remove Storage::save() 2020-01-08 04:13:12 +06:00
Temirkhan Myrzamadi
c69e685e00 Add Dispatcher::save_storage() 2020-01-08 03:39:32 +06:00
Temirkhan Myrzamadi
707e69fb27 Add the first version 2020-01-08 03:32:47 +06:00
Temirkhan Myrzamadi
7fd4f3b4a5 Bullsiht 2020-01-06 23:51:31 +06:00
Temirkhan Myrzamadi
05bc12df85 Polish the docs of FilterDispatcher 2020-01-06 05:55:01 +06:00
Temirkhan Myrzamadi
0668987b2d Fix derives 2020-01-05 09:14:04 +06:00
Temirkhan Myrzamadi
5da3e1610e Fix rustfmt 2020-01-05 02:41:11 +06:00
Temirkhan Myrzamadi
6830013922
Merge pull request #123 from teloxide/update-deps
Update the dependencies
2020-01-05 02:36:56 +06:00
Temirkhan Myrzamadi
24d76b59b3 Update the dependencies 2020-01-05 02:35:25 +06:00
Temirkhan Myrzamadi
6c69635f0d
Merge pull request #122 from selevit/markup_utils
Fix linter errors, enable ci for pull requests
2020-01-04 15:08:13 +06:00
Sergey Levitin
78f0bd4c0f Fix linter errors, enable ci for pull requests 2020-01-04 11:56:34 +03:00
Temirkhan Myrzamadi
f7d5f466da
Merge pull request #118 from selevit/markup_utils
Add HTML and Markdown formatting utils
2020-01-04 13:40:22 +06:00
Sergey Levitin
5f680cae50 Cargo fmt 2020-01-04 07:55:09 +03:00
Temirkhan Myrzamadi
e9c356c4df
Merge pull request #116 from teloxide/redesign_requests
Redesign requests
2020-01-04 02:29:44 +06:00
Sergey Levitin
d36b24c899 Gardening 2020-01-03 19:52:56 +03:00
Sergey Levitin
5bf49f4580 Cover all utils::html code 2020-01-03 19:46:37 +03:00
Sergey Levitin
f76f80c825 Gardening 2020-01-03 18:39:35 +03:00
Sergey Levitin
2e0e604658 Gardening 2020-01-03 18:21:29 +03:00
Sergey Levitin
a2879b8ea3 Implement HTML utils, refactor markdown utils with macroses 2020-01-03 18:01:34 +03:00
Sergey Levitin
2a66a84454 Add doc comments for the markdown utils module 2020-01-03 17:11:40 +03:00
Sergey Levitin
066271b397 Write markdown text formatting utils 2020-01-03 16:43:29 +03:00
Temirkhan Myrzamadi
2dcfc824f6 Create Request::Output 2020-01-03 17:41:42 +06:00
Temirkhan Myrzamadi
69e70b1d0e Fix Clippy 2020-01-03 15:54:26 +06:00
Temirkhan Myrzamadi
08d11a85d4 Use ChatOrInlineMessage 2020-01-03 15:40:43 +06:00
Sergey Levitin
eb44cd8b44 Improve namespacing 2020-01-03 04:04:50 +03:00
Sergey Levitin
fe2e1ecaf5 Add markdown escaping utils, simplify escape_html 2020-01-03 03:31:34 +03:00
Temirkhan Myrzamadi
4f9820ecd9 Add SendChatActionKind 2020-01-03 03:06:55 +06:00
Temirkhan Myrzamadi
1e5c8b0204 Fix InputFile::file 2020-01-03 02:28:27 +06:00
Temirkhan Myrzamadi
04de91253c Fix the docs 2020-01-03 02:23:28 +06:00
Temirkhan Myrzamadi
0b101a2523 Use InputFile instead of Into<InputFile> 2020-01-03 02:20:59 +06:00
Sergey Levitin
3cc5543cbc A little optimization for utils::escape::escape_html 2020-01-02 22:37:39 +03:00
Sergey Levitin
f42442f3b5 Add utils::escale::escape_html function 2020-01-02 22:26:25 +03:00
Temirkhan Myrzamadi
ce7f77e475 Fix the compilation error 2020-01-03 00:46:13 +06:00
Temirkhan Myrzamadi
d4a96e4a63 Return Bot's methods back 2020-01-03 00:38:40 +06:00
p0lunin
555df10880 make enum ApiErrorKind public 2020-01-02 16:19:26 +02:00
p0lunin
87dfd539c9 documentation 2020-01-02 16:19:03 +02:00
p0lunin
94c1fc1f75 rustfmt 2020-01-02 15:35:21 +02:00
p0lunin
c5b37adf5d add InvalidStickersSet 2020-01-02 15:05:51 +02:00
p0lunin
333ff8aa6b delete unknown errors 2020-01-02 15:05:26 +02:00
Temirkhan Myrzamadi
f2c09599e2 Fix Clippy 2020-01-02 18:43:09 +06:00
Temirkhan Myrzamadi
8d28debd31 Refactor 2020-01-02 18:29:43 +06:00
p0lunin
eada8c3184 added new errors 2020-01-02 13:12:06 +02:00
Temirkhan Myrzamadi
26fa7ffd06
Merge pull request #110 from teloxide/conversion_traits_for_parse_mode
Impl conversion traits for ParseMode
2020-01-02 16:29:17 +06:00
p0lunin
4d3d96be7c remove #[allow(depredecated)] in match 2020-01-02 12:17:56 +02:00
p0lunin
2a4b462996 rustfmt 2020-01-02 12:04:47 +02:00
Temirkhan Myrzamadi
cf3ac08d92 Push the wrong code 2020-01-02 14:50:04 +06:00
Temirkhan Myrzamadi
53f675c58a Move AllowedUpdate into teloxide::types 2020-01-02 03:31:35 +06:00
p0lunin
31326b2067 refactoring 2020-01-01 20:08:10 +02:00
p0lunin
9b2694657e updated to bot api v4.5 2020-01-01 20:01:40 +02:00
p0lunin
60532be947 refactoring 2020-01-01 20:01:26 +02:00
Waffle Lapkin
585c161511
Merge branch 'dev' into conversion_traits_for_parse_mode 2020-01-01 03:28:08 +03:00
Temirkhan Myrzamadi
e4e46d8df1 Fix teloxide::dispatching layout 2020-01-01 03:26:30 +06:00
Temirkhan Myrzamadi
2d5079ae37 Fix the links 2020-01-01 03:20:57 +06:00
Temirkhan Myrzamadi
1b89289de6 Fix Clippy 2020-01-01 01:16:47 +06:00
Temirkhan Myrzamadi
e4b0944160 Fix rustfmt again! 2020-01-01 00:35:44 +06:00
Temirkhan Myrzamadi
663e33d56b Fix rustfmt 2020-01-01 00:15:48 +06:00
p0lunin
9b21b6089b 5 2019-12-31 19:59:37 +02:00
Waffle
49a2195df9 Bot API 4.5 (December 31, 2019) updates 2019-12-31 20:58:48 +03:00
p0lunin
7cf9b4ab1f 5 2019-12-31 19:43:06 +02:00
Temirkhan Myrzamadi
fc1184087c Fix Clippy 2019-12-31 18:56:28 +06:00
Temirkhan Myrzamadi
5628f7111b Fix the conflicts 2019-12-31 18:45:19 +06:00
Temirkhan Myrzamadi
b0f85dea5b Fix grammatical mistakes in the docs 2019-12-31 17:16:01 +06:00