Maybe Waffle
3d69d96182
Fix chat unmark
2022-03-22 22:08:47 +04:00
Maybe Waffle
923be2221d
Add NotFound
error
2022-03-21 19:10:12 +04:00
Hirrolot
2c0748f3ae
Merge branch 'master' into with_payload
2022-03-20 08:08:52 -07:00
Maybe Waffle
d8e3c6ce42
Add WrongFileIdOrUrl
and FailedToGetUrlContent
errors
2022-03-18 14:21:55 +04:00
Maybe Waffle
c7e32fa247
Add HasPayload::with_payload_mut
function
...
`HasPayload::with_payload_mut` allows to easily apply multiple changes
to the payload without calling `payload_mut()` multiple times and
creating temporary variable for the request. e.g.:
```rust
// without `with_payload_mut`
{
let mut req = bot.set_webhook(url.clone());
req.payload_mut().certificate = certificate.take();
req.payload_mut().drop_pending_updates = drop_pending_updates;
req.send().await?;
}
// with `with_payload_mut`
bot
.set_webhook(url.clone())
.with_payload_mut(|payload| {
payload.certificate = certificate.take();
payload.drop_pending_updates = drop_pending_updates;
})
.send()
.await?
```
2022-03-18 14:13:38 +04:00
Waffle Maybe
0c5f9678d8
Merge pull request #185 from teloxide/revert_better_timeouts
...
Revert "better timeouts"
2022-03-07 20:16:53 +04:00
Maybe Waffle
5fb0a4787f
fix typos
2022-03-03 02:23:46 +03:00
Maybe Waffle
fbbb5c842b
Add User::is_telegram
2022-03-03 02:23:40 +03:00
Maybe Waffle
9eb51ad34b
fix clippy
2022-03-03 02:21:52 +03:00
Maybe Waffle
d5ad882999
fix typos
2022-03-03 01:45:41 +03:00
Maybe Waffle
812f6ef45e
Revert buggy "better timeouts"
2022-03-03 01:43:25 +03:00
mikhailantoshkin
686ec23b76
Add missing enum variants to the chat fucntion
2022-02-20 22:56:29 +05:00
Maybe Waffle
1d7825c97a
Prepare 0.4.2
release
2022-02-17 15:03:41 +03:00
Maybe Waffle
6bf204221f
Deprecate Message::chat_id
2022-02-17 14:51:00 +03:00
Maybe Waffle
3477f7eded
Fix sending quiz polls
2022-02-17 14:10:39 +03:00
Maybe Waffle
fb7710b838
Make GetUpdates
expose its timeout
via Payload::timeout_hint
2022-02-14 19:53:19 +03:00
Maybe Waffle
2dc4a915ba
Add a way for long-running requests to increase network timeout
2022-02-14 19:52:43 +03:00
Maybe Waffle
8d89fdccbd
Fix Update
de/serialization tests
2022-02-13 20:58:33 +03:00
Maybe Waffle
c0795f0dc9
Add regression test for issue 523
2022-02-13 20:53:58 +03:00
Maybe Waffle
fb523f153e
Fix deserialization of UntilDate
2022-02-13 20:53:41 +03:00
Waffle Maybe
d83f7180c4
Merge pull request #175 from teloxide/tba_5.7
...
TBA 5.7
2022-02-03 17:39:16 +03:00
Waffle Maybe
1c2a38eeb6
Merge pull request #173 from teloxide/docs_examples_blah
...
Change process of building docs
2022-02-03 17:38:52 +03:00
Flattergaster
82eb96b405
Fix deserialization of ChatInviteLink::pending_join_request_count
2022-02-02 22:38:03 +03:00
Maybe Waffle
c34a1386df
Fix test
2022-02-01 21:14:09 +03:00
Maybe Waffle
044f33551e
TBA 5.7: Add Sticker{,Set}::is_video
2022-02-01 20:12:26 +03:00
Maybe Waffle
6384560195
TBA 5.7: Add InputSticker::Webm
2022-02-01 19:39:29 +03:00
Maybe Waffle
16630133db
Add regression test for WebhookInfo
with an empty url
2022-02-01 18:31:04 +03:00
Maybe Waffle
a36794c5d3
Make WebhookInfo::allowed_updates
typed
2022-02-01 18:30:40 +03:00
Maybe Waffle
dde40e613f
Change process of building docs
...
- introduce `docs` alias that does the right thing (tm)
- use `-Zrustdoc-scrape-examples`
2022-01-31 18:23:30 +03:00
Hirrolot
bd4218c238
Merge branch 'master' into input_file_refactor
2022-01-30 20:14:30 +06:00
Maybe Waffle
38f2a5fef2
Make WebhookInfo::ip_address
typed
2022-01-27 20:25:40 +03:00
Maybe Waffle
6598ed9f42
Remove redundant settings from default_reqwest_settings
2022-01-19 22:34:12 +03:00
Maybe Waffle
df88d83cfd
Fix documentation
2022-01-13 20:43:33 +03:00
Maybe Waffle
622b0d9232
Remove dbg!
...
:/
2022-01-13 17:14:55 +03:00
Maybe Waffle
bc440b9ea8
fix clippy
2022-01-13 17:14:24 +03:00
Maybe Waffle
ef33f9f66a
Add more tests for multipart request serialization
2022-01-13 17:14:24 +03:00
Maybe Waffle
5b4ed3faa9
Allow sending impl AsyncRead
...
This commit adds `InputFile::read` constructor that creates `InputFile`
from an `impl AsyncRead + Send + Unpin + 'static`.
Internally this requires quite a bit of work, since we need to support
cloning `InputFile`s but the `AsyncRead` trait only allows us reading it
once.
To support this, if `InputFile` detects that it's shared, it reads the
contents of the `AsyncRead` into a buffer and then shares the buffer
(or an error if it has occured).
2022-01-13 17:14:24 +03:00
Maybe Waffle
a84e897db9
Refactor multipart requests
...
This removes the logic in the multipart serializer that unserialized
`InputFile`s from serde. Now `InputFile`s are serialized either as
their value (for `FileId` and `Url`) or as an `attach://<id>` string
where `<id>` is replaced with some id unique for the file. The file data
itself is acquired through `MultipartPayload` trait.
Since the `<id>` must be the same while serializing the file with serde
and while acquiring data through `MultipartPayload` trait, `InputFile`
needs to store said id. As such, `InputFile` is now a structure with
private fields and it's structure can't be observed by users. The only
things that `InputFile` provides are
- Constructors (`url`, `file_id`, `file`, `memory`)
- File name setter
- `Clone` and `Debug` implementations
2022-01-13 17:14:13 +03:00
Waffle Maybe
7958f37c60
Apply suggestions from code review
2022-01-13 10:28:33 +03:00
Waffle Maybe
cfb3c60a1c
Apply suggestions from code review
2022-01-13 10:05:46 +03:00
Giga Maxim
f02ed38bb7
update comment in src/types/webhook_info.rs
...
Co-authored-by: Waffle Maybe <waffle.lapkin@gmail.com>
2022-01-12 19:49:30 +03:00
Max Giga
f2d98fdb8a
fixed serialization error not returning empty string
2022-01-12 19:47:35 +03:00
Max Giga
834c54c1d6
refactor_serialization_deserialization_of_url
2022-01-12 19:35:07 +03:00
Max Giga
ba2305dbe5
set empty url in WebhookInfo to None
2022-01-12 16:51:57 +03:00
Maybe Waffle
4a04750790
Remove stray generics
2022-01-12 13:46:25 +03:00
Maybe Waffle
bed5805610
File refactor: specify InputFile-ish fields for multipart payloads
2022-01-12 12:21:51 +03:00
Maybe Waffle
96266228d8
File refactor: InputMedia: remove derive(Deserialize), add
files`
2022-01-12 12:21:38 +03:00
Maybe Waffle
c92190e313
Un-seal MultipartPayload
2022-01-12 11:28:35 +03:00
Hirrolot
dad5d5d4b1
Merge pull request #156 from teloxide/tolerant_updates_for_all
...
Make update deserialization fault tolerant by default
2022-01-12 15:19:24 +07:00
Waffle Maybe
53df041940
Merge pull request #163 from zggff/master
...
make OrderInfo use Option<String> instead of String. It allows teloxide to ask only one needed field of the shipping query.
2022-01-12 11:18:37 +03:00
Hirrolot
1bcf621c7d
Merge branch 'master' into tolerant_updates_for_all
2022-01-12 15:14:37 +07:00
Hirrolot
95dc6e5881
Merge pull request #162 from teloxide/tba_5.6
...
Add support for TBA 5.6
2022-01-12 15:10:47 +07:00
Maybe Waffle
488492e9e5
Move Chat::has_protected_content
to ChatPublic
2022-01-11 16:12:02 +03:00
Maybe Waffle
22159867bb
Add Chat::has_protected_content
2022-01-11 15:51:28 +03:00
zggff
b72df9b657
make successful payment use OrderInfo; derive Default on OrderInfo
2022-01-05 10:58:53 +03:00
zggff
1d0ff0a0f6
make OrderInfo use Option<String> instead of String
2022-01-04 23:21:48 +03:00
Maybe Waffle
7223270b32
Add support for TBA 5.6
2022-01-03 21:41:57 +03:00
Waffle Maybe
4af317e1fd
Merge pull request #159 from Mr-Andersen/master
...
Fix deserializing `Document`
2022-01-02 19:55:54 +03:00
Андрей Власов
3047bea3ab
Use serde(default)
where applicable
2022-01-02 19:43:37 +03:00
Waffle Maybe
22d2586949
Merge pull request #160 from teloxide/fix_cfg_docs
...
Fix `doc(cfg)` implication
2022-01-02 19:31:50 +03:00
Maybe Waffle
4d0ed16054
Fix doc(cfg)
implication
2022-01-02 19:20:56 +03:00
Андрей Власов
19bcd8a6ba
Remove unnecessary code
2022-01-02 18:35:14 +03:00
Андрей Власов
db8175e9f9
Fix deserializing Document
2022-01-02 18:34:49 +03:00
Андрей Власов
93690a3417
Fix "no test
in tokio
"
2022-01-02 18:33:15 +03:00
Maybe Waffle
ea67c634ad
Fix clippy
2021-12-29 23:15:38 +03:00
Maybe Waffle
59720c1e0b
Remove get_updates_fault_tolerant
and SemiparsedVec
2021-12-29 21:35:30 +03:00
Maybe Waffle
62e9e8afd4
Make ChatPermissions into bitflags
2021-12-29 20:36:08 +03:00
Maybe Waffle
648b5b7377
Make UpdateKind
deserialization fault tolerant
2021-12-29 18:06:28 +03:00
Waffle Maybe
fd3ef0bdf3
Merge pull request #154 from teloxide/bot_command_scope_fix
...
Fix serialization of `BotCommandScope::Chat{,Administrators}`
2021-12-28 17:07:46 +03:00
Maybe Waffle
f456ab110a
Add ApiError::NotEnoughRightsToChangeChatPermissions
2021-12-28 17:04:19 +03:00
Maybe Waffle
f65617e763
Fix serialization of BotCommandScope::Chat{,Administrators}
2021-12-28 16:09:40 +03:00
Hirrolot
ff21d876c4
Merge branch 'master' into fix_some_message_deserialization_bugs
2021-12-28 19:49:08 +07:00
Hirrolot
54f4281754
Merge pull request #150 from teloxide/invalid_json_raw
...
Add `RequestError::InvalidJson::raw` field
2021-12-25 14:03:58 +06:00
Waffle Maybe
468b0c9379
Merge pull request #153 from teloxide/more_message_serialization_bug_fixes
...
Fix deserialization of `VoiceChat{Started,Ended}` messages
2021-12-25 11:02:55 +03:00
Maybe Waffle
9ce53a2b02
Fix deserialization of VoiceChat{Started,Ended}
messages
2021-12-25 04:50:31 +03:00
Maybe Waffle
34647c7a38
Improve debug_assert!
message in ChatId::unmark
2021-12-25 04:34:05 +03:00
Maybe Waffle
078ee1d7ce
Refactor forwarded messages
2021-12-25 04:27:13 +03:00
Maybe Waffle
2bd19a598e
Add User::is_anonymous
and User::is_channel
functions
...
Also add documentation for `User::{full_name, mention, url}`
2021-12-25 04:12:59 +03:00
Maybe Waffle
1bcb062d88
Add RequestError::InvalidJson::raw
field
2021-12-24 15:47:54 +03:00
Maybe Waffle
3f2d69702f
Update changelog and add regression test for issue 481
2021-12-19 18:52:03 +03:00
Maybe Waffle
1e0b8b6734
Fix deserialization of MediaKind::Venue
2021-12-19 18:38:47 +03:00
Sprite
234ac365db
Update changelog and comment the PR link in the test
2021-12-19 21:26:39 +08:00
Sprite
06a21ba9e1
Skip the language
field of MessageEntityKind::Pre
if it is None
2021-12-19 21:25:51 +08:00
Maybe Waffle
40a5860085
Suppress clippy
2021-12-19 14:56:20 +03:00
Hirrolot
22de637798
Merge pull request #143 from teloxide/api55
...
TBA 5.5
2021-12-19 17:16:45 +06:00
Maybe Waffle
ef0d2d3aea
fix clippy
...
Use chars, instead of strings when using `str::replace` in tests.
2021-12-10 17:19:43 +03:00
Maybe Waffle
f42c1a6098
Fix deserialization of chat migrations
2021-12-10 17:00:49 +03:00
Maybe Waffle
df5487a04b
fix clippy
...
Use chars, instead of strings when using `str::replace` in tests.
2021-12-09 14:54:21 +03:00
Maybe Waffle
604a5cc91b
TBA 5.5 types updates
2021-12-09 14:54:21 +03:00
Maybe Waffle
c566494b7d
Add TBA v5.5 methods
2021-12-09 14:54:07 +03:00
Maybe Waffle
560fa36e41
re-run payloads codegen
2021-12-07 01:31:49 +03:00
Waffle Maybe
e3a0087644
Merge pull request #140 from SpriteOvO/master
...
Add the missing method `caption_entities` to `InputMediaPhoto`
2021-12-07 01:08:42 +03:00
Sprite
a5a1277636
Fix the incorrect response type of CopyMessage
method
2021-12-07 04:13:52 +08:00
Sprite
0724964682
Add the missing method caption_entities
to InputMediaPhoto
2021-11-28 02:21:46 +08:00
Sprite
abfd92a102
Add the missing field media_group_id
to MediaDocument
& MediaAudio
2021-11-27 17:11:18 +08:00
Waffle Maybe
bbd92a004c
Merge pull request #138 from teloxide/warn_pring_dbg
...
Enable clippy to warn on dbg/print usage
2021-11-25 13:04:25 +03:00
Maybe Waffle
fc0dc9b2b9
Enable clippy to warn on dbg/print usage
...
Also remove old #![allow] that was used to supress clippy bug.
2021-11-25 13:01:21 +03:00
Maybe Waffle
c4b148459d
Add regression test for issue 473
2021-11-20 19:50:15 +03:00
Maybe Waffle
3ccf624168
Fix multipart MessageEntity
serialization
2021-11-20 19:50:15 +03:00
Maybe Waffle
706bd08c6b
Fix docs
2021-11-15 01:47:54 +03:00
Maybe Waffle
45183d4dcd
fix test
2021-11-15 01:47:54 +03:00
Maybe Waffle
8002f98ef7
Add TBA 5.4 types
2021-11-15 01:46:53 +03:00
Maybe Waffle
094211e6a1
Add TBA v5.4 methods and params
...
(schema update)
2021-11-15 01:46:53 +03:00
Maybe Waffle
9fb6c20f23
Make SendPoll::type_
optional
...
(fix from schema)
2021-11-15 01:46:53 +03:00
Maybe Waffle
9bcdd37be0
Remove PartialEq, Eq, Hash
derives from InputFile
...
...and tg-method-structs holding it
2021-11-15 01:46:53 +03:00
Maybe Waffle
af54d6db7a
Fix conflict between PRs 134 and 135
2021-11-13 20:16:13 +03:00
Hirrolot
461d882bc1
Merge pull request #134 from teloxide/errfactor
...
Refactor errors
2021-11-13 19:09:22 +06:00
Maybe Waffle
8d1dd8d444
Add ApiError::TooMuchInlineQueryResults
2021-11-09 21:16:56 +03:00
Maybe Waffle
27e1b90c6e
Refactor errors
2021-11-08 00:02:17 +03:00
Waffle Maybe
00abf2fd80
Merge pull request #131 from berkus/fix/add-derive-debug
...
fix: Add missing derive(Debug) on adapters
2021-11-07 13:27:13 +03:00
Berkus Decker
f868152e2f
fix: Add missing derive(Debug) on adapters
2021-11-07 12:22:05 +02:00
Waffle Maybe
839181bffd
Merge pull request #127 from teloxide/must_use_requests
...
Add `#[must_use]` attrs to payload setters, request wrappers and send* methods
2021-10-24 23:10:25 +03:00
Hirrolot
8ee25a616c
Merge pull request #128 from teloxide/inline_methods_fix
...
Fix `*_inline` methods (release v0.3.4)
2021-10-18 18:04:13 +06:00
Maybe Waffle
bd8bafd03b
Fix *_inline methods (release v0.3.4)
2021-10-18 13:47:02 +03:00
Maybe Waffle
73235682a3
Add #[must_use]
attrs to payload setters, request wrappers and send* methods
2021-10-15 19:07:41 +03:00
Waffle Maybe
6e6cabb5b7
Merge pull request #126 from teloxide/imply_doc_cfg
...
Remove explicit `doc(cfg)` as it's now implied
2021-10-11 17:26:29 +03:00
Waffle Maybe
2ceb2c5782
Merge pull request #125 from teloxide/api_error_non_exhaustive
...
Mark `ApiError` as `non_exhaustive`
2021-10-11 17:26:04 +03:00
Maybe Waffle
62d21d1c58
Remove explicit doc(cfg) as it's now implied
2021-10-11 16:58:15 +03:00
Maybe Waffle
25db4901e2
Mark ApiError
as non_exhaustive
2021-10-10 16:40:31 +03:00
Maybe Waffle
037e0eaf41
Add some sticker errors
2021-10-10 16:33:40 +03:00
Maybe Waffle
d3be288eba
Add NotEnoughRightsToPostMessages
error
2021-10-10 14:59:06 +03:00
Waffle
00b83770a7
Throttle: correct limits for channels
...
This commits adds `Limits::messages_per_min_channel` field
2021-09-16 02:51:28 +03:00
Waffle
86a478dd1d
Throttle: fix limit check
...
Previously both `messages_per_sec_chat` and `messages_per_min_chat` were
checked against last second message count.
2021-09-16 00:04:01 +03:00
Andrew
602c573b92
Fix type of Poll::open_period
field: i32
=> u16
2021-09-07 15:35:07 +05:00
Andrew
6d4ad2932c
Fix type of Poll::correct_option_id
field: i32
=> u8
2021-09-07 15:32:00 +05:00
Waffle
842315150b
Add UntilDate
enum and use it for {Restricted, Banned}::until_date
2021-09-02 18:14:54 +03:00
Waffle
0e55b41961
Patch BanChatMember::until_date
: u64
-> DateTime<Utc>
2021-09-02 17:18:27 +03:00
Hirrolot
3d7ca29681
Merge pull request #115 from teloxide/make_urls_urlier
...
Use `url::Url` for urls, use `chrono::DateTime<Utc>` for dates in types
2021-08-31 07:50:38 -07:00
Hirrolot
16a3ba3349
Merge pull request #113 from teloxide/dont_reparse_url_on_every_request
...
Do not re-parse default tba url on every request
2021-08-31 07:50:21 -07:00
Waffle
d3bf4499ea
Use url::Url
for urls, use chrono::DateTime<Utc>
for dates in types
2021-08-31 17:45:20 +03:00
hex0x0000
2c53236af4
Fixed url formatting and a typo
...
Fixed formatting
Merging suggestion
Co-authored-by: Waffle Lapkin <waffle.lapkin@gmail.com>
Fixed other typos
2021-08-28 14:36:31 +02:00
Waffle
a422f97480
Do not re-parse default tba url on every request
2021-08-28 14:54:40 +03:00
Hirrolot
261be16b47
Merge pull request #106 from teloxide/use_tokio_task_unconstrained
...
Use `tokio::task::unconstrained` when using `.now_or_never()` to prevent some problems I guess
2021-08-22 01:55:23 -07:00
Waffle
2417b636a6
Add EditedMessageIsTooLong
error
2021-08-21 23:59:59 +03:00
Waffle
5349c85404
Fix compilation with nigthly
feature
...
The `min_type_alias_impl_trait` feature was removed in faviour of `type_alias_impl_trait`.
2021-08-03 02:29:26 +03:00
Waffle
0471cb0322
Use tokio::task::unconstrained
when using .now_or_never()
to prevent some problems I guess
...
The issue in fixme says to use `tokio::task::unconstrained`.
2021-07-23 20:08:26 +03:00
Waffle
2abd9b17a6
Fix typo in docs
2021-07-16 22:41:50 +03:00
Waffle
4ccedd7f77
suppress clippy
2021-07-12 17:07:20 +03:00
Waffle
1fe4518ee9
Add tools for Bot/Request type erasure
2021-07-12 16:58:51 +03:00
Waffle
33236f79e6
Document trace_adaptor
feature
2021-07-11 15:58:09 +03:00
Waffle
9e8819d726
Add Trace
bot adaptor
2021-07-10 17:41:20 +03:00
Waffle
5aa622b361
impl HasPayload
, Request
and Requester
for either::Either
...
This allows to use different adaptors depending on runtime context.
2021-07-08 13:04:40 +03:00
Waffle
23c125775c
Remove Self: 'static
buound on RequesterExt::throttle
2021-07-07 20:14:27 +03:00
Waffle
e7b44e6bbe
Use cfg(dep_docsrs)
to allow building docs properly as a dependency
2021-07-07 20:14:25 +03:00
Waffle
df69d07f2b
Bump version (0.2.2 => 0.3.0)
2021-07-04 17:36:07 +03:00
Waffle
5ac43d4ac0
Fix type of PhotoSize::{width,height}
fields: i32
=> u32
2021-07-04 17:36:07 +03:00
Waffle
44c1cfd420
Remove keyboad
method (typo, was fixed to keyboard in 0.2.2)
2021-07-04 17:36:07 +03:00
Waffle
e6b66a7383
TBA 5.3: update changelog and supported version
2021-07-04 16:06:06 +03:00
Waffle
120ed97e8c
TBA 5.3: Update methods
2021-07-04 16:06:06 +03:00
Waffle
27f5875b42
TBA 5.3: Add BotCommandScope
2021-07-04 16:06:06 +03:00
Waffle
ef84162314
Use DateTime<Utc>
for until_date
in ChatMember
2021-07-04 16:06:06 +03:00
Waffle
c3a00c687a
TBA 5.3: rename chat member statuses: Creator
=> Owner
, Kicked
=> Banned
2021-07-04 16:06:06 +03:00
Waffle
2c65fea742
TBA 5.3: Add input_field_placeholder
to KeyboardMarkup
and ForceReply
2021-07-04 14:56:25 +03:00
Hirrolot
52313b740c
Merge pull request #96 from teloxide/throttle_settings
...
Make `Throttle` settings more extendable
2021-07-04 07:59:56 +06:00
Hirrolot
9e7685e7b4
Merge branch 'master' into throttle_settings
2021-07-04 07:53:09 +06:00
Hirrolot
40c712e1d6
Merge branch 'master' into typed_urls_dates
2021-07-04 07:37:21 +06:00
Waffle
fa980453f3
Ignore buggy nonstandard_macro_braces clippy lint
2021-07-04 00:11:27 +03:00
Waffle
421cf42835
Use url::Url
for urls, use chrono::DateTime<Utc>
for dates
2021-07-03 23:35:13 +03:00
Waffle
4377abd149
Make Throttle
settings more extendable
...
Add a `#[non_exhaustive]` `Settings` builder struct.
Replace `with_queue_full_fn` and `spawn_with_queue_full_fn` with
`with_settings` and `spawn_with_settings`.
This allows to add more settings in the future without breaking changes.
2021-07-03 22:34:31 +03:00
Waffle
1661f9f955
Throttle: Avoid repeatedly calling queue_full
2021-06-29 21:24:04 +03:00
Waffle
6450d9227d
Add Throttle::{with_queue_full_fn, spawn_with_queue_full_fn}
2021-06-29 21:24:04 +03:00
Waffle
07676a7156
Throttle: log when queue is full
2021-06-29 21:24:04 +03:00
Waffle
58cbf45bac
Remove QueueStatus
2021-06-29 21:22:42 +03:00
Waffle
34e73748c3
Add a way to get info from/into Thrrotle
...
This patch adds `Thrrotle::{limits,set_limits,queue_status}` functions and
`QueueStatus` struct allowing to get current status of worker & change
limits of the fly.
2021-06-29 21:22:40 +03:00
Waffle
0dc565211f
Add DefaultParseMode::parse_mode
2021-06-29 21:21:47 +03:00
Waffle
656e393779
Fix rt-tys of {get,set}_my_commands
methods
...
Fix return types of `get_my_commands` (`u32` => `True`) and `set_my commands`
(`u32` => `Vec<BotCommand>`).
2021-06-24 20:49:26 +03:00
liushuyu
414ce2c3a6
telegram_response: fix issue with handling ...
...
... `retry_after` and `migrate_to_chat_id`
2021-06-19 03:16:30 -06:00
Waffle
c1eca613d5
Fix Clippy: remove useless (immediately implicitly dereferenced) refs
2021-06-09 11:34:40 +03:00
Waffle Lapkin
8ea42fe871
Resolve FIXME in HasPayload
: we've decided to not add As{Mut,Ref}
bounds
2021-06-09 11:09:14 +03:00
Waffle
77253422f8
clippy
2021-05-30 13:34:20 +03:00
Waffle
961d67ccf1
Fix formatting of ParseMode
docs
2021-05-21 16:58:04 +03:00
Waffle Lapkin
6ac0ed8588
Apply suggestions from code review
...
Co-authored-by: Hirrolot <hirrolot@gmail.com>
2021-05-13 18:43:07 +03:00
Waffle
ecaa5d5bec
Add net::default_reqwest_settings
function
...
This function can help when users want to set up their own client setting for
one reason or another, since settings set by the function, are required for
stable work.
This function was previously private and named `sound_bot`. The old name was
confusing since safety and soundness are used in the Rust context almost
entirely for `unsafe` code, UB & co. So I've changed the name to a more
descriptive one.
2021-05-12 11:51:03 +03:00
Waffle
728313174f
Use proper notable_trait attr
2021-05-08 23:49:00 +03:00
Temirkhan Myrzamadi
7faec64f95
Fix Clippy
2021-05-04 23:51:11 +06:00
Hirrolot
a068166e8d
Merge branch 'master' into api-5.2
2021-05-04 10:41:29 -07:00
Waffle Lapkin
ce1a9ece16
Merge branch 'master' into private_url
2021-05-04 18:31:18 +03:00
Waffle
c498872778
Fix clippy
2021-05-04 18:20:08 +03:00
Waffle
6c0eb174ed
Move macro around
2021-05-04 16:50:49 +03:00
Waffle
39c497ca1e
Update methods to TBA 5.2
2021-05-04 16:47:16 +03:00
Waffle
653c804037
Update types to TBA 5.2
2021-05-04 16:01:18 +03:00
handlerug
8a7909e7c7
Add BotKickedFromSupergroup error
...
Fixes teloxide/teloxide#372
2021-04-27 23:48:27 +07:00
handlerug
b3dec316e5
Add NotEnoughRightsToManagePins error
...
Fixes teloxide/teloxide#371
2021-04-27 23:41:14 +07:00
Hirrolot
1d20dace9a
Merge pull request #81 from teloxide/fix_docs
...
Fix docs
2021-04-27 06:46:34 -07:00
Waffle
a95089bc6f
Fix docs
...
`doc_spotlight` nightly feature was renamed to `doc_notable_trait`
2021-04-27 12:25:15 +03:00
Waffle
a7d07a770c
Update CHANGELOG and remove unused imports
2021-04-27 12:17:14 +03:00
Waffle
ce969564ac
Improve Message::url
...
Return urls to messages in private groups (t.me/c) when applicable.
2021-04-27 12:01:19 +03:00
Waffle
bd52e93cdb
Add missing Chat::message_auto_delete_time
field (tba 5.1)
2021-04-27 12:00:54 +03:00
Waffle
b55bdd274b
Add Chat
getters
...
Add getters for all `Chat` fields nested in `ChatKind`.
`Chat` has a lot of nested enums and so is hard to match on.
The getters help with this.
This patch also corrects type of `slow_mode_delay`: `Option<i32>`` -> `Option<u32>``
2021-04-27 11:42:31 +03:00
Waffle
5d0713e742
Fix return types of methods
...
Fix return types of LeaveChat, PinChatMessage, SetChatDescription, SetChatPhoto,
SetChatTitle, UnpinAllChatMessages and UnpinChatMessage: String => True
2021-04-22 17:34:47 +03:00
Waffle
c73e73ad02
fmt
2021-03-30 16:38:24 +03:00
Waffle Lapkin
ccdcda68d4
Merge branch 'master' into chat_member_methods
2021-03-30 16:26:46 +03:00
Waffle Lapkin
747898c310
Apply suggestions from code review
...
Co-authored-by: Hirrolot <hirrolot@gmail.com>
2021-03-30 16:24:41 +03:00
Waffle Lapkin
5b99565289
Apply suggestions from code review
...
Co-authored-by: Hirrolot <hirrolot@gmail.com>
2021-03-30 16:22:49 +03:00
Waffle Lapkin
16d0852e4a
Apply suggestions from code review
...
Co-authored-by: Hirrolot <hirrolot@gmail.com>
2021-03-30 15:04:44 +03:00
Hirrolot
2ab7d30ad2
Merge pull request #76 from teloxide/derive_clone
...
`impl Clone` for {`CacheMe<_>`, `DefaultParseMode<_>`, `Throttle<_>`}
2021-03-30 04:41:13 -07:00
Waffle
44a044af02
impl Clone
for {CacheMe<_>
, DefaultParseMode<_>
, Throttle<_>
}
2021-03-30 12:17:49 +03:00
Waffle
528187d7e6
Fix SendChatAction return type
2021-03-29 13:49:52 +03:00
Waffle
23cf363271
Prevent year 2038 problem in ChatMember
...
This patch changes the Type of `{Restricted,Kicked}::until_date` fields:
`i32` => `i64`.
This is done to fix so called "year 2038 problem"
(See <https://en.wikipedia.org/wiki/Year_2038_problem >).
2021-03-29 10:20:03 +03:00
Waffle
3522a23289
fix docs
2021-03-29 10:16:02 +03:00