INNER CODE UNIT · Python

run_sanity

crocs-muni/javacard-curated-list · scripts/process_curated_list.py:439

def run_sanity(path, offline=False):
    print(f"Extracting markdown from {path} ...", file=sys.stderr)
    markdown_text = load_markdown_text(path)

    print("Parsing repository entries...", file=sys.stderr)
    entries = parse_entries(markdown_text)
    print(f"  found {len(entries)} entries", file=sys.stderr)

    print("Checking badge links for structural issues...", file=sys.stderr)
    for e in entries:
        e["issues"] = structural_issues_for_entry(e)

    if not offline:
        github_entries = [e for e in entries if e["main_owner_repo"]]
        print(f"Fetching live badge data to check for unresolvable entries ({len(github_entries)} repos)...",
              file=sys.stderr)
        with ThreadPoolExecutor(max_workers=10) as pool:
            future_to_entry = {pool.submit(data_issues_for_entry, e): e for e in github_entries}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…