【发布时间】:2020-12-15 18:31:34
【问题描述】:
我有一个 json 文件:
[{"uid": x, "username": "x", "firstname": "x", "lastname": "x", "access_hash": x}, {"uid": y, "username": "y", "firstname": "y", "lastname": "y", "access_hash": y}]
我想在循环中删除对象 {"uid[...]"access-hash": x}
我有以下代码:
try:
user_to_add = InputPeerUser(user['uid'], user['access_hash'])
add = await client(InviteToChannelRequest(target_group_entity,[user_to_add]))
print(gr+'Added ', str(user['uid']))
#remove the object where I used uuid acces_hash and so on
我希望有人可以帮助我,并提前联系!
【问题讨论】:
-
请重新填写tour,阅读help center 和How to Ask,并提供minimal reproducible example。 “为我实现此功能”与此站点无关。您必须做出诚实的尝试,然后针对您的算法或技术提出具体问题。