Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2018-11-26 12:51:03

Destry
Moderator
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,014
Website

Txp plugin to interface with the fediverse

There’s a lot of discussion and development going on these days towards blogging capabilities in the fediverse. You might not see this discussion if you’re not actually in the fediverse, however.

One of the first projects in this direction was Plume, which is gradually marching along.

Another, which some worried was a ‘open-washing’-ware at first has ultimately emerged as fully open and fine, Write Freely. The dev is the same guy behind Write.As, and the M’don instance I’m on, writing.exchange.

There are one or two others in development along the line of Plume that I can’t recall or find off-hand.

But the latest emergence in this direction, and the reason for posting now, is this this plugin for WordPress, Pterotype. (Hosted WP or other, I’m not certain.)

I think this is a smart move, because lots of people in the f’verse are clamouring for a federated blogging solution, and many already use something like WordPress, whatever, so this interfacing seems like a logical way forward for those that don’t want to use a new blogging tool. And the ability to use the f’verse steam as a kind of comments system (a la G+, etc) is attractive too.

What would need to happen for a similar Txp plugin. I mean, is it technically possible? I can only assume so, but you know me. I wouldn’t know what this looks like on the Txp admin-side yet, but probably nothing outlandish there. But just rough-conception-thinking: maybe you install plugin, which has an associated ActivityPub-flavoured theme, a generic one, then one can customize the theme?

Just punting this out there, because based on what I’m witnessing, the fediverse is growing in popularity, and the projects emerging from it are new, or, in the case of WP, interfacing with it in a compatible way. I’m guessing if Txp hopes to garner any interest at all from this new frontier, it might want to think about interfacing too, even if just a plugin.

Plus, it gives you’ll a new standard to learn, Activity Pub, which may in fact be a very important one before too long. ;)


The text persuades, the *notes prove。

Offline

#2 2018-11-26 13:25:01

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 8,458
Website

Re: Txp plugin to interface with the fediverse

I think it’s technically possible. A plugin needs to:

  • Have a way of specifying endpoint(s), presumably via Prefs (the “Outbox” in the W3C Overview) that will be notified of events.
  • Hook into the ping event to send a notification to the endpoint(s) when an article is published. Caveat: only send it once, even if an article’s status is altered (Txp might handle this already, I can’t remember).
  • Hook into comment.saved so that comments get posted to the endpoint(s).
  • Run a server to poll for replies (the “Inbox”). Somehow get this to run either asynchronously, or at least on some/all page views.
  • Read the external comments and either merge them with those in the database on-the-fly or inject them into the DB.

Things to consider:

  • Handling federated comments in real time (increased network latency) vs pulling them into the database and serving them from there (more robust, but possibly leads to stale content and privacy concerns if someone wants to exercise their right to be forgotten etc).
  • Moderated comments. Incoming messages would need to be queued on the Content->Comments panel and subject to review as normal. Is a notification sent out that the comment has been accepted at this point?
  • Granular control required so only content from some Sections is publicised?
  • Spam.

The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#3 2018-11-27 15:08:33

Destry
Moderator
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,014
Website

Re: Txp plugin to interface with the fediverse

Bloke wrote #315412:

  • Handling federated comments in real time (increased network latency) vs pulling them into the database and serving them from there (more robust, but possibly leads to stale content and privacy concerns if someone wants to exercise their right to be forgotten etc).

I’m pretty sure for this to fly in spirit of the fediverse, you’d have to deal with them in real-time. The most aggressive proponents of privacy, infosec, etc are in the f’verse right now. That’s kind of the whole point for a lot of people there.

And the transient nature of instances, people lilypad hopping across them while adding/dropping accounts, and the increasing popularity of purging one’s fediverse posts after some given number of days (which I’m thinking about doing)… Storing anything, or requiring a request for deletion of said info, would dissuade interest from people potentially looking at Txp for the plugin’s functionality, or raise hackles in extreme cases.

  • Moderated comments. Incoming messages would need to be queued on the Content->Comments panel and subject to review as normal. Is a notification sent out that the comment has been accepted at this point?
  • Granular control required so only content from some Sections is publicised?
  • Spam.

I can’t remember how the G+ hack worked (and Facebook, etc), but one could use that as a comment’s replacement (catering to only G+ posts). Was it possible to selectively queue and remove other people’s G+ posts that were tied to an blog article you posted, for example?

In any case, I think one of the assumptions about using something like this, in relation to the fediverse, is you’re willing to deal with what people have to share. My experience with fediverse is pretty good. The worst a-holes, most of them, are still in centralized platforms. When they dare to show up, they’re identified and quarantined pretty fast across the f’verse.

Also notable is decentralized instances serve as the first layer of shit control through strong admin policies and CoC’s. So far it’s a pretty strongly-policed space. That doesn’t mean it’s perfect or couldn’t see a flare up of fools in the future, but it’s nature means Txp isn’t the front line. That might be good enough for a lot of people who are already good at grooming their fediverse community. I may have went of track here with what we’re talking about, I don’t know. Just thinking aloud. ;)

I guess the trick would be to hook into the privacy mute/block etc controls on the fediverse site. I’m guessing that’s in the Activity Pub api.

Not to divert conversation but I just heard about this FOSS alternative to Disqus, Schnack.


The text persuades, the *notes prove。

Offline

#4 2018-11-27 15:22:55

Destry
Moderator
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,014
Website

Re: Txp plugin to interface with the fediverse

Hmm.. Schnack seems to work with Mastodon…

All you have to do is to define app_name and app_website in the oauth.mastodon section of your config.json. Schnack will then create OAuth applications at Mastodon instances whenever a user tries to sign in (the users are asked to enter a Mastodon domain before signing in).

Meaning it’s probably pretty easy to make work with Pleroma, etc too… Anything Activity Pub, I guess.


The text persuades, the *notes prove。

Offline

#5 2018-11-29 23:01:05

Destry
Moderator
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,014
Website

Re: Txp plugin to interface with the fediverse

I seemed to have missed this post from the Pterotype dev. Sounds like he’s trying to make it easier for plugin devs of other systems too.

My goal is to provide a well-tested, flexible library that handles the complicated parts of ActivityPub (JSON-LD, persistence, addressing, etc.) in a way that can be plugged into an existing PHP codebase with no hassle. That’ll help me refactor #Pterotype, and will also make it easy for other developers to make developers to make plugins for Joomla, Drupal, etc.

That’s a big step further than using Schnack to enable Mastodon-posts-as-comments integration, but both are nice directions.


The text persuades, the *notes prove。

Offline

Board footer

Powered by FluxBB