Commit 41aafcf
authored
feat(website): comprehensive SEO overhaul and blog scaffold (#1340)
* feat: support binary WebSocket frames in message handlers
Closes #1332
Propagate binary WebSocket frames (opcode 0x2) through the entire
Rust→Python pipeline instead of silently echoing them back.
- Add WsPayload enum (Text/Binary) to replace String throughout the
WebSocket channel, registry messages, and send methods
- Forward ws::Message::Binary through the channel so Python handlers
receive bytes for binary frames and str for text frames
- Accept str|bytes in send/broadcast methods, emitting the correct
frame type on the wire
- Add receive() returning str|bytes, fix receive_text/receive_bytes
to validate frame type
Made-with: Cursor
* fix: harden WebSocket API safety and update type stubs
- Replace UUID unwrap() with proper error handling in sync_send_to and
async_send_to, returning PyValueError instead of panicking
- Update robyn.pyi type stubs to accept str | bytes for send/broadcast
methods, matching the Rust implementations
- Add warning log in extract_ws_return for unsupported handler return
types to aid debugging
Made-with: Cursor
* fix: add Python 3.14 to linux-cross matrix and bump maturin
- Add cp314-cp314 entry to the linux-cross build matrix
- Bump pinned maturin from v1.12.0 to v1.12.6 to support Python 3.14's
build-details.json format (missing extension_suffix field)
Made-with: Cursor
* docs: update WebSocket docs for binary frame support
- Document new receive() and send() methods for mixed text/binary frames
- Add binary and mixed-frame code examples to both EN and ZH docs
- Update API reference tables with receive(), send(), and updated
descriptions for receive_text/bytes, send_bytes, and broadcast
- Note that receive_text/receive_bytes now raise TypeError on wrong
frame type
Made-with: Cursor
* feat(website): comprehensive SEO overhaul and blog scaffold
Addresses critical SEO gaps across the Robyn website:
- Add robots.txt and auto-generated sitemap via next-sitemap
- Create reusable SEO component with canonical URLs, hreflang (en/zh),
Open Graph, Twitter Cards, and JSON-LD structured data
- Fix placeholder @yourTwitterHandle → @robaborobyn
- Add per-page meta tags to community, releases, and docs pages
- Add JSON-LD schemas: WebSite, SoftwareSourceCode, Organization,
BreadcrumbList, TechArticle
- Fix hardcoded lang="en" → dynamic locale from Next.js
- Fix empty alt attributes on logo, testimonial photos, release images
- Replace raw <a> tags with Next.js <Link> for internal navigation
- Fix heading hierarchy (community h2→h1)
- Fix "wor oad" typo in testimonial
- Add custom 404 page
- Add site.webmanifest with proper icon declarations
- Scaffold blog section with index, [slug] dynamic routes, and
sample welcome post
- Add Blog link to header and footer navigation
- Rename package.json from template name to robyn-website
Made-with: Cursor
* fix: address PR review findings across website and websocket code
Website/SEO fixes:
- Fix hreflang duplication: use router.locales/defaultLocale and strip
locale prefix from path before building alternates
- Escape JSON-LD output to prevent script-breakout via frontmatter
- Remove references to non-existent favicon PNGs, use existing robynog.png
- Add aria-current="page" to active breadcrumb item in blog posts
- Guard getStaticProps/getBlogPostBySlug against missing files (return
notFound: true)
- Use siteUrl variable in next-sitemap alternateRefs instead of hardcoded URL
- Strip query strings and hash fragments in breadcrumb path builder
- Wrap fetchStars in useCallback and add to useEffect dependency array
- Use dynamic locale for docs link in 404 page
- Extract shared formatDate utility to deduplicate blog components
Rust/Python fixes:
- Rename sender_id → recipient_id in robyn.pyi stubs to match Rust bindings
- Remove repr() logging from extract_ws_return to prevent data leakage
- Add WsPayload::Close variant to replace "Connection closed" magic string
- Switch WebSocket message channel from unbounded to bounded (cap 256)
- Log warning when bounded channel is full/closed instead of silently dropping
- Propagate registry try_send errors to Python as exceptions instead of
swallowing with Ok(())
Made-with: Cursor
* fix: normalize SITE_URL, UTC dates, websocket channel lifecycle
- Trim trailing slashes from SITE_URL to prevent double-slash URLs
- Add timeZone: 'UTC' to formatDate to prevent off-by-one display
for negative UTC offsets
- Stop cloning message_sender into Python-facing WebSocketConnector
clones so the channel properly closes when the actor stops
- Send terminal None through channel before dropping sender in
stopped() so receive() returns None on disconnect
- Consume SendMessage payload by value instead of borrowing and
cloning to avoid unnecessary allocations
Made-with: Cursor
* fix: remove WebSocket binary frame changes from docs-only branch
Reverts WebSocket code and doc changes that were accidentally included
in the SEO overhaul branch. These belong on feat/binary-websocket-frames.
Made-with: Cursor
* fix: revert release-CI.yml changes from docs-only branch
Made-with: Cursor1 parent 2e70726 commit 41aafcf
23 files changed
Lines changed: 835 additions & 141 deletions
File tree
- docs_src
- public
- src
- components
- documentation
- releases
- content/blog
- lib
- pages
- blog
- releases
- src/websockets
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
| 39 | + | |
38 | 40 | | |
39 | 41 | | |
40 | 42 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
0 commit comments