File tree Expand file tree Collapse file tree 2 files changed +3
-16
lines changed
Expand file tree Collapse file tree 2 files changed +3
-16
lines changed Original file line number Diff line number Diff line change @@ -288,27 +288,14 @@ async def get_creator_info_by_id(self, creator_id: str) -> Dict:
288288
289289 """
290290 uri = "/api/container/getIndex"
291- container_info = await self .get_creator_container_info (creator_id )
292- if container_info .get ("fid_container_id" ) == "" or container_info .get ("lfid_container_id" ) == "" :
293- utils .logger .error (f"[WeiboClient.get_creator_info_by_id] get containerid failed" )
294- raise DataFetchError ("get containerid failed" )
291+ containerid = f"100505{ creator_id } "
295292 params = {
296293 "jumpfrom" : "weibocom" ,
297294 "type" : "uid" ,
298295 "value" : creator_id ,
299- "containerid" : container_info [ "fid_container_id" ] ,
296+ "containerid" :containerid ,
300297 }
301-
302298 user_res = await self .get (uri , params )
303-
304- if user_res .get ("tabsInfo" ):
305- tabs : List [Dict ] = user_res .get ("tabsInfo" , {}).get ("tabs" , [])
306- for tab in tabs :
307- if tab .get ("tabKey" ) == "weibo" :
308- container_info ["lfid_container_id" ] = tab .get ("containerid" )
309- break
310-
311- user_res .update (container_info )
312299 return user_res
313300
314301 async def get_notes_by_creator (
Original file line number Diff line number Diff line change @@ -293,7 +293,7 @@ async def get_creators_and_notes(self) -> None:
293293 # Get all note information of the creator
294294 all_notes_list = await self .wb_client .get_all_notes_by_creator_id (
295295 creator_id = user_id ,
296- container_id = createor_info_res . get ( "lfid_container_id" ) ,
296+ container_id = f"107603 { user_id } " ,
297297 crawl_interval = 0 ,
298298 callback = weibo_store .batch_update_weibo_notes ,
299299 )
You can’t perform that action at this time.
0 commit comments