reywechat 1.0.76__py3-none-any.whl → 1.0.78__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- reywechat/rdb.py +13 -18
- reywechat/rreceive.py +1 -2
- reywechat/rsend.py +7 -8
- {reywechat-1.0.76.dist-info → reywechat-1.0.78.dist-info}/METADATA +1 -1
- {reywechat-1.0.76.dist-info → reywechat-1.0.78.dist-info}/RECORD +7 -7
- {reywechat-1.0.76.dist-info → reywechat-1.0.78.dist-info}/WHEEL +0 -0
- {reywechat-1.0.76.dist-info → reywechat-1.0.78.dist-info}/licenses/LICENSE +0 -0
reywechat/rdb.py
CHANGED
@@ -80,11 +80,6 @@ class WeChatDatabase(WeChatBase):
|
|
80
80
|
'wechat.stats': 'stats'
|
81
81
|
}
|
82
82
|
|
83
|
-
# Check.
|
84
|
-
if 'sqlite' in (self.database_wechat.backend, self.database_file.backend):
|
85
|
-
text = 'not suitable for SQLite databases'
|
86
|
-
throw(AssertionError, text=text)
|
87
|
-
|
88
83
|
# Add handler.
|
89
84
|
self.__add_receiver_handler_to_contact_user()
|
90
85
|
self.__add_receiver_handler_to_contact_room()
|
@@ -763,7 +758,7 @@ class WeChatDatabase(WeChatBase):
|
|
763
758
|
|
764
759
|
## Insert.
|
765
760
|
if contact_table != []:
|
766
|
-
conn.
|
761
|
+
conn.execute.insert(
|
767
762
|
(self.db_names['wechat'], self.db_names['wechat.contact_user']),
|
768
763
|
user_data,
|
769
764
|
'update'
|
@@ -819,7 +814,7 @@ class WeChatDatabase(WeChatBase):
|
|
819
814
|
|
820
815
|
## Insert.
|
821
816
|
if contact_table != []:
|
822
|
-
conn.
|
817
|
+
conn.execute.insert(
|
823
818
|
(self.db_names['wechat'], self.db_names['wechat.contact_room']),
|
824
819
|
room_data,
|
825
820
|
'update'
|
@@ -897,7 +892,7 @@ class WeChatDatabase(WeChatBase):
|
|
897
892
|
|
898
893
|
## Insert.
|
899
894
|
if room_user_data != []:
|
900
|
-
conn.
|
895
|
+
conn.execute.insert(
|
901
896
|
(self.db_names['wechat'], self.db_names['wechat.contact_room_user']),
|
902
897
|
room_user_data,
|
903
898
|
'update'
|
@@ -965,7 +960,7 @@ class WeChatDatabase(WeChatBase):
|
|
965
960
|
}
|
966
961
|
|
967
962
|
## Insert.
|
968
|
-
self.database_wechat.
|
963
|
+
self.database_wechat.execute.insert(
|
969
964
|
(self.db_names['wechat'], self.db_names['wechat.contact_user']),
|
970
965
|
data,
|
971
966
|
'update'
|
@@ -1006,7 +1001,7 @@ class WeChatDatabase(WeChatBase):
|
|
1006
1001
|
## Insert.
|
1007
1002
|
|
1008
1003
|
### 'contact_room'.
|
1009
|
-
self.database_wechat.
|
1004
|
+
self.database_wechat.execute.insert(
|
1010
1005
|
(self.db_names['wechat'], self.db_names['wechat.contact_room']),
|
1011
1006
|
data,
|
1012
1007
|
'update'
|
@@ -1028,7 +1023,7 @@ class WeChatDatabase(WeChatBase):
|
|
1028
1023
|
}
|
1029
1024
|
|
1030
1025
|
## Update.
|
1031
|
-
self.database_wechat.
|
1026
|
+
self.database_wechat.execute.update(
|
1032
1027
|
(self.db_names['wechat'], self.db_names['wechat.contact_room']),
|
1033
1028
|
data
|
1034
1029
|
)
|
@@ -1050,7 +1045,7 @@ class WeChatDatabase(WeChatBase):
|
|
1050
1045
|
}
|
1051
1046
|
|
1052
1047
|
## Update.
|
1053
|
-
self.database_wechat.
|
1048
|
+
self.database_wechat.execute.update(
|
1054
1049
|
(self.db_names['wechat'], self.db_names['wechat.contact_room']),
|
1055
1050
|
data
|
1056
1051
|
)
|
@@ -1130,7 +1125,7 @@ class WeChatDatabase(WeChatBase):
|
|
1130
1125
|
}
|
1131
1126
|
|
1132
1127
|
# Insert.
|
1133
|
-
self.database_wechat.
|
1128
|
+
self.database_wechat.execute.insert(
|
1134
1129
|
(self.db_names['wechat'], self.db_names['wechat.message_receive']),
|
1135
1130
|
data,
|
1136
1131
|
'ignore'
|
@@ -1173,7 +1168,7 @@ class WeChatDatabase(WeChatBase):
|
|
1173
1168
|
}
|
1174
1169
|
|
1175
1170
|
# Update.
|
1176
|
-
self.database_wechat.
|
1171
|
+
self.database_wechat.execute.update(
|
1177
1172
|
(self.db_names['wechat'], self.db_names['wechat.message_send']),
|
1178
1173
|
data
|
1179
1174
|
)
|
@@ -1241,7 +1236,7 @@ class WeChatDatabase(WeChatBase):
|
|
1241
1236
|
' )\n'
|
1242
1237
|
')'
|
1243
1238
|
)
|
1244
|
-
result = conn.
|
1239
|
+
result = conn.execute.select(
|
1245
1240
|
(self.db_names['wechat'], self.db_names['wechat.message_send']),
|
1246
1241
|
['send_id', 'type', 'receive_id', 'parameter', 'file_id'],
|
1247
1242
|
where,
|
@@ -1326,7 +1321,7 @@ class WeChatDatabase(WeChatBase):
|
|
1326
1321
|
|
1327
1322
|
## User.
|
1328
1323
|
if message.room is None:
|
1329
|
-
result = message.receiver.wechat.database.database_wechat.
|
1324
|
+
result = message.receiver.wechat.database.database_wechat.execute.select(
|
1330
1325
|
(self.db_names['wechat'], self.db_names['wechat.contact_user']),
|
1331
1326
|
['valid'],
|
1332
1327
|
'`user_id` = :user_id',
|
@@ -1336,7 +1331,7 @@ class WeChatDatabase(WeChatBase):
|
|
1336
1331
|
|
1337
1332
|
## Room.
|
1338
1333
|
elif message.user is None:
|
1339
|
-
result = message.receiver.wechat.database.database_wechat.
|
1334
|
+
result = message.receiver.wechat.database.database_wechat.execute.select(
|
1340
1335
|
(self.db_names['wechat'], self.db_names['wechat.contact_room']),
|
1341
1336
|
['valid'],
|
1342
1337
|
'`room_id` = :room_id',
|
@@ -1413,7 +1408,7 @@ class WeChatDatabase(WeChatBase):
|
|
1413
1408
|
data['file_id'] = file_id
|
1414
1409
|
|
1415
1410
|
# Insert.
|
1416
|
-
self.database_wechat.
|
1411
|
+
self.database_wechat.execute.insert(
|
1417
1412
|
(self.db_names['wechat'], self.db_names['wechat.message_send']),
|
1418
1413
|
data
|
1419
1414
|
)
|
reywechat/rreceive.py
CHANGED
@@ -9,7 +9,6 @@
|
|
9
9
|
"""
|
10
10
|
|
11
11
|
|
12
|
-
from __future__ import annotations
|
13
12
|
from typing import Any, TypedDict, Literal, overload
|
14
13
|
from collections.abc import Callable
|
15
14
|
from queue import Queue
|
@@ -92,7 +91,7 @@ class WeChatMessage(WeChatBase):
|
|
92
91
|
|
93
92
|
def __init__(
|
94
93
|
self,
|
95
|
-
receiver: WechatReceiver,
|
94
|
+
receiver: 'WechatReceiver',
|
96
95
|
time: int,
|
97
96
|
id_: int,
|
98
97
|
number: int,
|
reywechat/rsend.py
CHANGED
@@ -9,7 +9,6 @@
|
|
9
9
|
"""
|
10
10
|
|
11
11
|
|
12
|
-
from __future__ import annotations
|
13
12
|
from typing import Any, Literal, overload
|
14
13
|
from collections.abc import Callable
|
15
14
|
from enum import IntEnum
|
@@ -86,7 +85,7 @@ class WeChatSendParameters(WeChatBase):
|
|
86
85
|
@overload
|
87
86
|
def __init__(
|
88
87
|
self,
|
89
|
-
sender: WeChatSender,
|
88
|
+
sender: 'WeChatSender',
|
90
89
|
send_type: Literal[WeChatSendTypeEnum.TEXT],
|
91
90
|
receive_id: str,
|
92
91
|
send_id: int | None = None,
|
@@ -97,7 +96,7 @@ class WeChatSendParameters(WeChatBase):
|
|
97
96
|
@overload
|
98
97
|
def __init__(
|
99
98
|
self,
|
100
|
-
sender: WeChatSender,
|
99
|
+
sender: 'WeChatSender',
|
101
100
|
send_type: Literal[WeChatSendTypeEnum.TEXT_AT],
|
102
101
|
receive_id: str,
|
103
102
|
send_id: int | None = None,
|
@@ -109,7 +108,7 @@ class WeChatSendParameters(WeChatBase):
|
|
109
108
|
@overload
|
110
109
|
def __init__(
|
111
110
|
self,
|
112
|
-
sender: WeChatSender,
|
111
|
+
sender: 'WeChatSender',
|
113
112
|
send_type: Literal[WeChatSendTypeEnum.FILE, WeChatSendTypeEnum.IMAGE, WeChatSendTypeEnum.EMOTION],
|
114
113
|
receive_id: str,
|
115
114
|
send_id: int | None = None,
|
@@ -121,7 +120,7 @@ class WeChatSendParameters(WeChatBase):
|
|
121
120
|
@overload
|
122
121
|
def __init__(
|
123
122
|
self,
|
124
|
-
sender: WeChatSender,
|
123
|
+
sender: 'WeChatSender',
|
125
124
|
send_type: Literal[WeChatSendTypeEnum.PAT],
|
126
125
|
receive_id: str,
|
127
126
|
send_id: int | None = None,
|
@@ -132,7 +131,7 @@ class WeChatSendParameters(WeChatBase):
|
|
132
131
|
@overload
|
133
132
|
def __init__(
|
134
133
|
self,
|
135
|
-
sender: WeChatSender,
|
134
|
+
sender: 'WeChatSender',
|
136
135
|
send_type: Literal[WeChatSendTypeEnum.PUBLIC],
|
137
136
|
receive_id: str,
|
138
137
|
send_id: int | None = None,
|
@@ -148,7 +147,7 @@ class WeChatSendParameters(WeChatBase):
|
|
148
147
|
@overload
|
149
148
|
def __init__(
|
150
149
|
self,
|
151
|
-
sender: WeChatSender,
|
150
|
+
sender: 'WeChatSender',
|
152
151
|
send_type: Literal[WeChatSendTypeEnum.FORWARD],
|
153
152
|
receive_id: str,
|
154
153
|
send_id: int | None = None,
|
@@ -158,7 +157,7 @@ class WeChatSendParameters(WeChatBase):
|
|
158
157
|
|
159
158
|
def __init__(
|
160
159
|
self,
|
161
|
-
sender: WeChatSender,
|
160
|
+
sender: 'WeChatSender',
|
162
161
|
send_type: WeChatSendTypeEnum,
|
163
162
|
receive_id: str,
|
164
163
|
send_id: int | None = None,
|
@@ -3,14 +3,14 @@ reywechat/rall.py,sha256=5J_X-XMOyb1Vp1jyS9-oRFXGOtp2vRPX1g3tJot_Eck,371
|
|
3
3
|
reywechat/rbase.py,sha256=hbxn5spvcl_C_Bw8A9teulOXT9GMlxUw145_YbXIOzc,1124
|
4
4
|
reywechat/rcache.py,sha256=5FIa8UB3VsLHT_EXHHmFP62a5AeS22anJCJXC8t4tWw,908
|
5
5
|
reywechat/rclient.py,sha256=ayOtQ0CaF8ydXjirLdVed8FbpfdQVTKVSd0x4grs-pQ,22712
|
6
|
-
reywechat/rdb.py,sha256=
|
6
|
+
reywechat/rdb.py,sha256=pu_8i_e0RRmyD6Oc1lHvgomipCyt5bfpMZQDA-7u9yQ,50804
|
7
7
|
reywechat/rlog.py,sha256=TSA-_5pwlq0sUND2cnLDqXvdmAdMAkC7tXIz3WfJ7Xw,5259
|
8
|
-
reywechat/rreceive.py,sha256=
|
9
|
-
reywechat/rsend.py,sha256=
|
8
|
+
reywechat/rreceive.py,sha256=YPMW99BDfgdv-6LdWE0C1NNQdh_FWVclcMMMioe74lo,50972
|
9
|
+
reywechat/rsend.py,sha256=MUpLeVeKc-9zswARqB3WLDmaOPLpAtN_u4788MHWoC8,20079
|
10
10
|
reywechat/rtrigger.py,sha256=c0peI208K2k2sOxtuszD8UMrhMrTGp0LMi_XE5ksJKg,4989
|
11
11
|
reywechat/rwechat.py,sha256=g0pbprMPv_qWb_lGFrPDAWsJO4vPSIgFLkw0Y28CZUo,4751
|
12
12
|
reywechat/data/client_api.dll,sha256=H9uj-x9Ztg0jFZK0yY6NsnyH5_119dQRFfoVVMidxRs,592384
|
13
|
-
reywechat-1.0.
|
14
|
-
reywechat-1.0.
|
15
|
-
reywechat-1.0.
|
16
|
-
reywechat-1.0.
|
13
|
+
reywechat-1.0.78.dist-info/METADATA,sha256=1EAY_ivFfmAkobkWeV9iPZY_rH1DjSp5GHxCnHsK3iM,1551
|
14
|
+
reywechat-1.0.78.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
15
|
+
reywechat-1.0.78.dist-info/licenses/LICENSE,sha256=UYLPqp7BvPiH8yEZduJqmmyEl6hlM3lKrFIefiD4rvk,1059
|
16
|
+
reywechat-1.0.78.dist-info/RECORD,,
|
File without changes
|
File without changes
|