Add Webmentions support #1

Merged
blacklight merged 38 commits from feature/webmentions into main 2026-02-11 02:01:09 +01:00
Owner
  • Expose Webmentions callback
  • Store Webmentions
  • Send Webmentions
    • Scan for file modifications
    • Parse URLs in posts and scan for Webmention hooks
    • Add Webmention dispatcher thread
  • Fetch title and icon from source page if not provided
  • Render Webmentions as comments
  • Support multiple content formats
  • Add HTML->Markdown parser if needed
  • Add Microformats2 parser if needed
  • Manage updates
  • Manage deletions
  • Approvals
  • Email notifications
  • Throttling

Closes: #2

- [x] Expose Webmentions callback - [x] Store Webmentions - [x] Send Webmentions - [x] Scan for file modifications - [x] Parse URLs in posts and scan for Webmention hooks - [x] Add Webmention dispatcher thread - [x] Fetch title and icon from source page if not provided - [x] Render Webmentions as comments - [x] Support multiple content formats - [x] Add HTML->Markdown parser if needed - [x] Add Microformats2 parser if needed - [x] Manage updates - [x] Manage deletions - [x] Approvals - [ ] Email notifications - [x] Throttling Closes: #2
blacklight changed title from WIP: feat(webmentions): Added support for receiving and storing Webmentions to WIP: Add Webmentions support 2026-01-15 01:20:11 +01:00
Will implement a more granular moderation system later.
Webmentions should distinguish between incoming and outgoing mentions.

This commit introduces the WebmentionDirection enum to represent the
direction of a Webmention, allowing for clearer handling of inbound and
outbound mentions within the system.
- Removed unnecessary parse_metadata method.
- Adjusted verify_webmention to return the response text directly.
- Moved webmention verification and parsing code from
  `WebmentionsHandler` to `WebmentionsParser`
- Updated `process_webmention_request` to utilize the new parser for
  extracting mention data
- Simplified data handling for webmentions by consolidating data
  extraction in the new parser class
- Ensured rigorous error handling for source and target URLs within the
  parser
- Updated README.md to include webmentions configuration and usage
  instructions.
- Modified config.example.yaml to include options for enabling
  webmentions and hard deletes.
- Enhanced app.py to handle datetime formatting.
- Updated config.py to include webmention configuration fields.
- Introduced WebmentionGone exception for non-existent webmentions.
- Developed storage functionalities in _storage.py to handle incoming
  webmentions with soft and hard deletes.
- Updated _model.py to introduce webmention status and improved data
  handling in webmention parsing.
- Adjusted _parser.py to correctly handle webmention validation and
  status updates.
- Split webmentions logic into dedicated incoming/outgoing processors under
  webmentions/_handlers and introduce WebmentionsHandler as the façade.
- Introduce WebmentionsStorage ABC and add FileWebmentionsStorage backend for
  persisting inbound/outbound webmentions in the content tree.
- Add filesystem content watcher (watchdog) to detect content changes and trigger
  outgoing webmention processing automatically.
- Update app lifecycle (cli/app) to start/stop the watcher and update the
  webmention endpoint to use the new incoming API.
- Add watchdog dependency (requirements/setup).
blacklight changed title from WIP: Add Webmentions support to Add Webmentions support 2026-02-11 02:00:56 +01:00
blacklight deleted branch feature/webmentions 2026-02-11 02:01:09 +01:00
Sign in to join this conversation.
No description provided.