62 Commits

Author SHA1 Message Date
Akulij
0ca057c064 create test for BotNotification 2025-06-02 16:43:53 +05:00
Akulij
c9dc1fb479 create tests for BotNotification deserealization 2025-06-02 12:03:28 +05:00
Akulij
91bf739365 update BotNotification specification 2025-06-02 12:03:16 +05:00
Akulij
57652c2776 fix: infinite try_from deserealization 2025-06-02 12:02:28 +05:00
Akulij
fd7c813b0e create specification for notifications 2025-06-02 11:39:44 +05:00
Akulij
a106891050 create call_attacher for Runner to attach global objects on initialization 2025-05-31 13:42:54 +05:00
Akulij
9cd0765030 create BotMessage js function handler getter 2025-05-31 13:42:10 +05:00
Akulij
bc46e0fda4 create BotFunction context getter 2025-05-31 13:41:42 +05:00
Akulij
845071c800 create botscript application module for js's runtime user_application function 2025-05-31 13:39:17 +05:00
Akulij
3bd16a58cd add replace flag to BotMessage 2025-05-31 10:34:29 +05:00
Akulij
474795bd99 create RunnerConfig.get_callback_message 2025-05-31 10:34:06 +05:00
Akulij
fdf1e352a6 add buttons field to BotDialog 2025-05-31 10:33:26 +05:00
Akulij
3acd168155 make Runner thread safe 2025-05-27 04:08:27 +05:00
Akulij
9bbf481002 derive Clone on bot and runner config 2025-05-26 20:48:11 +05:00
Akulij
4384431696 create RunnerConfig::init_with_db 2025-05-26 20:47:35 +05:00
Akulij
ff7f317ae5 create attach_db_obj for botscript 2025-05-26 20:44:34 +05:00
Akulij
aac968e408 add RawCallError to ScriptError 2025-05-26 20:43:04 +05:00
Akulij
1ff86f641f impl RunnerConfig::get_command_message 2025-05-23 16:27:06 +05:00
Akulij
31e78be68f change interface for ResolveValue 2025-05-23 16:26:35 +05:00
Akulij
217a074c95 create ResolveError 2025-05-23 16:24:17 +05:00
Akulij
1c17639c0e handle DbError in ScriptError 2025-05-23 16:23:54 +05:00
Akulij
9e35f4168e use DB and join_all 2025-05-23 16:23:12 +05:00
Akulij
178f2a2399 create ButtonRaw name, callback_name and literal getters 2025-05-23 16:21:26 +05:00
Akulij
1730107e9a create BotMessage.literal getter 2025-05-23 16:20:21 +05:00
Akulij
506fdcb260 create BotMessage.resolve_buttons 2025-05-23 16:19:37 +05:00
Akulij
6d5f748ab8 create ButtonLayout::resolve_raw 2025-05-23 16:15:44 +05:00
Akulij
cbb9c0c335 botscript: create ButtonLayout enum 2025-05-23 16:13:56 +05:00
Akulij
f8c63e5315 create BotMessage.fill_literal method 2025-05-23 16:04:03 +05:00
Akulij
66180e0cfb add optional literal string in BotMessage 2025-05-23 16:03:12 +05:00
Akulij
1117af0724 impl ButtonName.resolve_name 2025-05-23 15:49:30 +05:00
Akulij
ca2e661a0e fix: in Runner's init_config use deserialize_js instead of js_into 2025-05-21 14:06:09 +05:00
Akulij
c33c67044a delete test test_deserialization_main, since it isnot actual anymore 2025-05-21 13:04:08 +05:00
Akulij
d1b6d153d4 create call and call_args methods for BotFunction 2025-05-21 12:53:26 +05:00
Akulij
0dc71fda08 fix BotFunction's call_context method
previously called by stored template string instead of actual function
2025-05-21 12:46:46 +05:00
Akulij
970ce07280 fix name of stateful_msg_handlers in Parcelable field getter 2025-05-21 12:41:04 +05:00
Akulij
6fa398401d restore functions in deserialize_js 2025-05-21 12:28:24 +05:00
Akulij
6ea26c0618 change injectable template in DeserializeJS to correct one 2025-05-21 12:27:27 +05:00
Akulij
b76392d597 impl Parcelable for all RunnerConfig types 2025-05-21 12:26:09 +05:00
Akulij
ad58587160 fix test: use BotFunction's method by_name 2025-05-21 12:24:16 +05:00
Akulij
1aed17fa30 specify ResolveValue in recursive resolve call 2025-05-21 12:23:32 +05:00
Akulij
684895a554 change BotFunction implementation to be compatible with js function
injection
2025-05-21 12:19:39 +05:00
Akulij
d1b25b52c1 fix: use KeyboardDefinition in BotMessage 2025-05-20 08:49:52 +05:00
Akulij
2c5802eaeb delete unnecessary literal field in ButtonRaw 2025-05-20 08:49:23 +05:00
Akulij
a2e1354bee fix missing #[serde(untagged)] on keyboard layout structs 2025-05-20 08:47:23 +05:00
Akulij
55d53bd140 create keyboard struct definition with resolvement trait 2025-05-20 08:32:28 +05:00
Akulij
ea007127ff test for DeserializerJS::deserialize_js 2025-05-20 08:32:09 +05:00
Akulij
0a60b0469f create DeserializerJS::inject_templates 2025-05-20 08:29:40 +05:00
Akulij
40eec7d38d fix js_into: self is already a reference 2025-05-20 04:36:19 +05:00
Akulij
5c8cadf7a0 create test for deserealization of result of js function 2025-05-20 00:40:25 +05:00
Akulij
534a0e6090 create init_config method for Runner 2025-05-20 00:39:39 +05:00