@@ -61,28 +61,34 @@ async def on_invoke_activity(self, turn_context: TurnContext):
61
61
62
62
if turn_context .activity .name == "fileConsent/invoke" :
63
63
return await self .on_teams_file_consent (
64
- turn_context , FileConsentCardResponse (** turn_context .activity .value )
64
+ turn_context ,
65
+ FileConsentCardResponse ().deserialize (turn_context .activity .value ),
65
66
)
66
67
67
68
if turn_context .activity .name == "actionableMessage/executeAction" :
68
69
await self .on_teams_o365_connector_card_action (
69
70
turn_context ,
70
- O365ConnectorCardActionQuery (** turn_context .activity .value ),
71
+ O365ConnectorCardActionQuery ().deserialize (
72
+ turn_context .activity .value
73
+ ),
71
74
)
72
75
return self ._create_invoke_response ()
73
76
74
77
if turn_context .activity .name == "composeExtension/queryLink" :
75
78
return self ._create_invoke_response (
76
79
await self .on_teams_app_based_link_query (
77
- turn_context , AppBasedLinkQuery (** turn_context .activity .value )
80
+ turn_context ,
81
+ AppBasedLinkQuery ().deserialize (turn_context .activity .value ),
78
82
)
79
83
)
80
84
81
85
if turn_context .activity .name == "composeExtension/query" :
82
86
return self ._create_invoke_response (
83
87
await self .on_teams_messaging_extension_query (
84
88
turn_context ,
85
- MessagingExtensionQuery (** turn_context .activity .value ),
89
+ MessagingExtensionQuery ().deserialize (
90
+ turn_context .activity .value
91
+ ),
86
92
)
87
93
)
88
94
@@ -113,7 +119,9 @@ async def on_invoke_activity(self, turn_context: TurnContext):
113
119
return self ._create_invoke_response (
114
120
await self .on_teams_messaging_extension_configuration_query_settings_url (
115
121
turn_context ,
116
- MessagingExtensionQuery (** turn_context .activity .value ),
122
+ MessagingExtensionQuery ().deserialize (
123
+ turn_context .activity .value
124
+ ),
117
125
)
118
126
)
119
127
@@ -132,14 +140,16 @@ async def on_invoke_activity(self, turn_context: TurnContext):
132
140
if turn_context .activity .name == "task/fetch" :
133
141
return self ._create_invoke_response (
134
142
await self .on_teams_task_module_fetch (
135
- turn_context , TaskModuleRequest (** turn_context .activity .value )
143
+ turn_context ,
144
+ TaskModuleRequest ().deserialize (turn_context .activity .value ),
136
145
)
137
146
)
138
147
139
148
if turn_context .activity .name == "task/submit" :
140
149
return self ._create_invoke_response (
141
150
await self .on_teams_task_module_submit (
142
- turn_context , TaskModuleRequest (** turn_context .activity .value )
151
+ turn_context ,
152
+ TaskModuleRequest ().deserialize (turn_context .activity .value ),
143
153
)
144
154
)
145
155
@@ -280,7 +290,9 @@ async def on_teams_task_module_submit( # pylint: disable=unused-argument
280
290
async def on_conversation_update_activity (self , turn_context : TurnContext ):
281
291
282
292
if turn_context .activity .channel_id == Channels .ms_teams :
283
- channel_data = TeamsChannelData (** turn_context .activity .channel_data )
293
+ channel_data = TeamsChannelData ().deserialize (
294
+ turn_context .activity .channel_data
295
+ )
284
296
if turn_context .activity .members_added :
285
297
return await self .on_teams_members_added_dispatch_activity (
286
298
turn_context .activity .members_added , channel_data .team , turn_context
@@ -296,7 +308,7 @@ async def on_conversation_update_activity(self, turn_context: TurnContext):
296
308
if channel_data :
297
309
if channel_data .event_type == "channelCreated" :
298
310
return await self .on_teams_channel_created_activity (
299
- ChannelInfo (** channel_data .channel ),
311
+ ChannelInfo (). deserialize ( channel_data .channel ),
300
312
channel_data .team ,
301
313
turn_context ,
302
314
)
0 commit comments