nomadweb/scripts/inspect_book.py
eric ff7b721acb feat: NomadCNA community layer, social matching, payments, and ebook
Port meetups, discussions, gigs, dating/chat, VIP pay (ZPay/XorPay), MiroTalk live, digital academy, and ebook reader. Add persistent community_store, git-first deploy docs, and env template for production secrets.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-30 09:38:13 -05:00

36 lines
1.5 KiB
Python

import re
import urllib.request
html = urllib.request.urlopen("https://nomadweb.nomadro.com/book", timeout=30).read().decode("utf-8", "replace")
links = re.findall(r'href="([^"]+\.css[^"]*)"', html)
print("CSS count:", len(links))
for u in links[:15]:
print(" ", u)
print("ebook-section:", "ebook-section" in html)
print("viral-cover:", "viral-cover" in html)
print("flex class sample:", "min-h-screen" in html)
m = re.search(r"<body[^>]*>", html)
print("body:", m.group(0) if m else None)
# fetch first css and check for viral-title / flex
if links:
css_url = links[0]
if css_url.startswith("/"):
css_url = "https://nomadweb.nomadro.com" + css_url
try:
css = urllib.request.urlopen(css_url, timeout=30).read().decode("utf-8", "replace")
print("css0 len", len(css))
print("has viral-title", "viral-title" in css)
print("has .flex", ".flex{" in css or ".flex {" in css or re.search(r"\.flex\s*\{", css) is not None)
print("has min-h-screen", "min-h-screen" in css)
print("has max-w-6xl", "max-w-6xl" in css)
except Exception as e:
print("css fetch err", e)
# try all
for u in links:
full = u if u.startswith("http") else "https://nomadweb.nomadro.com" + u
try:
css = urllib.request.urlopen(full, timeout=30).read().decode("utf-8", "replace")
print(full, "len", len(css), "viral", "viral-title" in css, "flex", "min-h-screen" in css)
except Exception as e2:
print(full, e2)