(enabled: bool)
| 1007 | ) |
| 1008 | except Exception: |
| 1009 | journals = [{"id": name, "label": name, "enabled": True} for name in daily_agent.load_default_journals()] |
| 1010 | |
| 1011 | return { |
| 1012 | "arxiv_categories": arxiv_items, |
| 1013 | "conferences": conferences, |
| 1014 | "journals": journals, |
| 1015 | } |
| 1016 | |
| 1017 | |
| 1018 | @contextmanager |
| 1019 | def _local_only_feishu_doc_patch(enabled: bool): |
| 1020 | if not enabled: |
| 1021 | yield |
| 1022 | return |
| 1023 | with _FEISHU_DOC_PATCH_LOCK: |
| 1024 | original = reading_agent.create_doc |
| 1025 | |
| 1026 | def fake_create_doc(title: str, content: str, folder_id: Optional[str] = None) -> Dict[str, Any]: |
| 1027 | return { |
| 1028 | "url": None, |
| 1029 | "obj_token": None, |
| 1030 | "local_only": True, |
| 1031 | "title": title, |
| 1032 | "folder_id": folder_id, |
no outgoing calls
no test coverage detected