MCPcopy Create free account
hub / github.com/NanmiCoder/MediaCrawler / write_to_jsonl

Method write_to_jsonl

tools/async_file_writer.py:56–60  ·  view source on GitHub ↗
(self, item: Dict, item_type: str)

Source from the content-addressed store, hash-verified

54 await writer.writerow(item)
55
56 async def write_to_jsonl(self, item: Dict, item_type: str):
57 file_path = self._get_file_path('jsonl', item_type)
58 async with self.lock:
59 async with aiofiles.open(file_path, 'a', encoding='utf-8') as f:
60 await f.write(json.dumps(item, ensure_ascii=False) + '\n')
61
62 async def write_single_item_to_json(self, item: Dict, item_type: str):
63 file_path = self._get_file_path('json', item_type)

Callers 15

store_contentMethod · 0.80
store_commentMethod · 0.80
store_contentMethod · 0.80
store_commentMethod · 0.80
store_creatorMethod · 0.80
store_contactMethod · 0.80
store_dynamicMethod · 0.80
store_contentMethod · 0.80
store_commentMethod · 0.80
store_contentMethod · 0.80
store_commentMethod · 0.80
store_creatorMethod · 0.80

Calls 1

_get_file_pathMethod · 0.95

Tested by

no test coverage detected