MCPcopy Create free account
hub / github.com/OpenRaiser/PaperFlow / _daily_cache_matches_settings

Function _daily_cache_matches_settings

deployments/desktop/shared/agents.py:1140–1174  ·  view source on GitHub ↗
(
    cached_push: Dict[str, Any],
    *,
    days: int,
    limit_per_source: int,
    target_date: str,
    sources: Dict[str, Any],
)

Source from the content-addressed store, hash-verified

1138 for key, value in previous.items():
1139 if value is None:
1140 os.environ.pop(key, None)
1141 else:
1142 os.environ[key] = value
1143
1144
1145def health() -> Dict[str, Any]:
1146 return {
1147 "ok": True,
1148 "project_root": str(PROJECT_ROOT),
1149 "database": str(db_ops.DB_PATH),
1150 "database_exists": Path(db_ops.DB_PATH).exists(),
1151 }
1152
1153
1154def settings() -> Dict[str, Any]:
1155 source_preferences = {
1156 "enable_arxiv": _env_text("PAPERFLOW_ENABLE_ARXIV", "true").lower() not in {"0", "false", "no", "off"},
1157 "enable_semantic_scholar": _env_text("PAPERFLOW_ENABLE_SEMANTIC_SCHOLAR", "true").lower() not in {"0", "false", "no", "off"},
1158 "enable_openreview": _env_text("PAPERFLOW_ENABLE_OPENREVIEW", "true").lower() not in {"0", "false", "no", "off"},
1159 "enable_custom_rss": _env_text("PAPERFLOW_ENABLE_CUSTOM_RSS", "false").lower() in {"1", "true", "yes", "on"},
1160 "arxiv_categories": _env_list("PAPERFLOW_DEFAULT_ARXIV_CATEGORIES", ["cs.CL", "cs.AI", "cs.IR", "cs.LG"]),
1161 "conferences": _env_list("PAPERFLOW_DEFAULT_CONFERENCES", ["ICLR", "NeurIPS", "ACL", "SIGIR"]),
1162 "journals": _env_list("PAPERFLOW_DEFAULT_JOURNALS", []),
1163 "custom_rss_urls": _env_list("PAPERFLOW_CUSTOM_RSS_URLS", ["https://arxiv.org/rss/cs.CL"]),
1164 "conference_access_mode": _env_text("PAPERFLOW_CONFERENCE_ACCESS_MODE", "public") or "public",
1165 "auth_status": {
1166 "semantic_scholar_api_key": bool(_env_text("SEMANTIC_SCHOLAR_API_KEY")),
1167 "openreview_username": bool(_env_text("OPENREVIEW_USERNAME")),
1168 "openreview_token": bool(_env_text("OPENREVIEW_TOKEN")),
1169 "openreview_cookie_file": bool(_env_text("OPENREVIEW_COOKIE_FILE")),
1170 "conference_cookie_file": bool(_env_text("PAPERFLOW_CONFERENCE_COOKIE_FILE")),
1171 },
1172 }
1173 report_preferences = {
1174 "style": _env_text("PAPERFLOW_REPORT_STYLE", "standard") or "standard",
1175 "write_feishu": _env_bool("PAPERFLOW_WRITE_FEISHU", default=False),
1176 "wiki_ingest": _env_bool("PAPERFLOW_WIKI_INGEST", default=True),
1177 }

Callers 1

start_daily_push_taskFunction · 0.85

Calls 5

_to_floatFunction · 0.85
_normalized_cache_listFunction · 0.85
_cache_boolFunction · 0.85
getMethod · 0.80

Tested by

no test coverage detected