#known 2018-01-26

2018-01-26 UTC
[colinwalker], [kevinmarks], [miklb], [cleverdevil], tantek, [keithjgrant], [eddie], loicm, jeremycherfas and j12t joined the channel
z2xy and [miklb] joined the channel
#
jeremycherfas
Any idea why this request ignores the content field: curl -X POST -H 'User-Agent: shpub' -H 'Content-Type: application/x-www-form-urlencoded' -H 'Authorization: Bearer xxx' -d 'h=entry' -d 'bookmark-of=https://indieweb.org/bookmark' -d 'content=using a different label for description.' -d 'tags=#testtag' -d 'title=Description' 'https://stream.jeremycherfas.net/micropub/endpoint'
#
Zegnat
Hmm, has is ever been considered to add Known on Packagist, so people can just run `create-project` in composer to download it?
#
jeremycherfas
That would be useful
[xavierroy] joined the channel
#
Zegnat
Has anyone done likes and/or bookmarks with a Micropub client, instead of the Known posting interface? May or may not be broken, but would love to get confirmation from users.
#
Loqi
[Zegnat] Reading this, and what cweiske said, I almost think the Micropub code is taking your provided body, but the Like code discards it and only accepts “description”.
[andrea_arbogast joined the channel
#
Loqi
[Peter Vágner] Likes and Reposts handled by the @WithKnown Bookmarks plugin (part 2)
seekr_ joined the channel
#
[andrea_arbogast
Likes, reposts and bookmarks are broken from the Known UI, but work from micropub, except for the description issue
#
Zegnat
I read that post. But it didn’t seem to go into the Micropub issue too much.
seekr_ joined the channel
#
[andrea_arbogast
No, we are just figuring this out. I did some testing this morning and was able to get likes, reposts and bookmarks via Quill. If I use the Known interface, they all become bookmarks.
#
[andrea_arbogast
But my descriptions did not come through from Quill to Known
#
Zegnat
I feel like the Micropub description issue can just be fixed by doing a find and replace in the code and exchange “description” for “content”. But I am not running Known at the moment.
#
[andrea_arbogast
I can try that this weekend.
#
[andrea_arbogast
I think the fact that it works via micropub at all will be a happy revelation for folks
#
Zegnat
As can be seen in the chatlogs there, I was going purely from the code on GitHub and relying on jeremycherfas to tell me about actual-Known. I might find time to set-up Known myself this weekend.
#
[andrea_arbogast
Appreciate any help you can give!
[jeremycherfas], [miklb] and [cleverdevil] joined the channel
#
pvagner
Guys, that Bookmarks vs Reactions conflict is a night mare. In order to allow sharing via bookmarklet to the known site and generate Likes and Reactions I basically have to turn Likes, Bookmarks and Reposts into seperate entity subtypes. When doing that I think it's easier to discard Likes and Reposts from Bookmarks plugin and just use Reactions.
#
[cleverdevil]
Has anyone opened an issue on GitHub about this?
#
[cleverdevil]
Might be nice to get a consensus on the best path forward.
#
pvagner
There are infact two issues. One is here: https://github.com/kylewm/KnownReactions/issues/17
#
Loqi
[danito] #17 Likes not showing url
#
pvagner
And the second one is at https://github.com/idno/Known/issues/1753
#
Loqi
[chrisaldrich] #1753 Possible conflict with Core Like and KnownReactions Plugin
#
[cleverdevil]
Gotcha. Might be worthwhile to ping benwerd and @mapkyca on this, or send an email to the Known mailing list to see if a conversation could be sparked.
#
Zegnat
I was looking at it purely from a Known standpoint, haven’t even looked at how that plugin might affect things.
#
[cleverdevil]
The right solution is to get it fixed within core, not an external plugin.
#
pvagner
if you will look to those 2 articles I have posted on the subject, you will see I tried to move it all to what the core provides, but that is not sufficient and even if missing features will be implemented, it will become breaking. So perhaps Repost and Like handling should be removed from the built-in Bookmarks plugin. That might be easier than porting functionality from the Reactions plugin into Bookmarks plugin. And it
#
pvagner
will introduce no breaking changes hopefully.
#
[cleverdevil]
Known needs to support like-of, bookmark-of, et al in core itself.
#
[cleverdevil]
Well, that's my personal opinion at least 🙂
#
pvagner
Yes it should support these features by default i.e. they should be built-in.
#
pvagner
But I am saying let's trash Likes and Reactions handling from the Bookmarks plugin and pack Reactions plugin into the core.
#
[cleverdevil]
I could get behind that.
[jeremycherfas] joined the channel
#
[jeremycherfas]
This is separate from the way that bookmark-of discards the content if you try to use Micropub
#
[jeremycherfas]
And the Known API mangles description if you try to use that.
#
[cleverdevil]
Some work would need to be done in the Micropub endpoint, but it needs some work anyway.
#
[cleverdevil]
For a long time, I've wanted to see the Micropub endpoint to be refactored to enable the delegation of work to plugins.
#
[cleverdevil]
But, I am only a half-decent PHP developer at this point.
#
pvagner
[jeremycherfas]: Well, the core assumes body contains url the same way likeof, repostof or bokmark does. For title it assumes pageTitle like all the rest and it expect the description.
#
pvagner
camb: btwI'm also chatting via Riot and a part of some matrix.org explained down times and issues with the load it works perfectly for me all the time.
#
[jeremycherfas]
!tell pvagner Yes, but core accepts a description if I type it in by hand. It is only when using Micropub or the Known API that it refuses to use description.
#
Loqi
Ok, I'll tell them that when I see them next
#
Zegnat
[cleverdevil], that could definitely fix some stuff. The Micropub code is currently doing the translating of microformats properties, but there is no reason plugins couldn’t handle that themselves.
#
[cleverdevil]
They really *should* be handling that as much as possible.
#
[cleverdevil]
Given that the plugins define the Entities, they should define the mapping of those Entities to microformats.
#
Zegnat
The reason they don’t might be because it was decided to have Micropub itself as a plugin as well
#
[cleverdevil]
Sure, which is great, but very strongly limits the ability of new plugins to take advantage of Micropub.
#
[cleverdevil]
My Watching plugin, for example, has no way to enable creating posts via Micropub.
#
Zegnat
Hmm, I thought any entity can register itself?
#
[cleverdevil]
With the Micropub plugin? Not that I know of.
#
Zegnat
It goes through a method called getRegisteredForIndieWebPostType, so I thought you would be able to register. But I guess that means you can’t submit h-entry but would need to submit something like h-watched?
#
[cleverdevil]
Its a whole bunch of conditionals that hardcode the behavior.
#
Zegnat
I haven’t looked into the post type lookup code
#
Zegnat
[cleverdevil], I *think* this is how you register a h-type to go to you from the Micropub plugin, the Text plugin handles the `entry` type: https://github.com/idno/Known/blob/0ebe9aae3ba9c016854c4aaafad1bc5843830791/IdnoPlugins/Text/ContentType.php#L11
#
[cleverdevil]
Oh, interesting.
#
[cleverdevil]
Still, that's a very very simple case.
#
[cleverdevil]
And the creation of the entity still happens within the Micropub endpoint itself, I believe.
[miklb] joined the channel
#
Zegnat
No, Micropub endpoint will call the saveDataFromInput method on your plugin’s Entity class.
#
Zegnat
The Micropub code does some rewriting of the input data (mostly mapping from microformats vocab to internal Known vocab) before passing of to another entity. But e.g. a Watch post plugin doesn’t need that rewriting to happen and should be able to just work.
#
Zegnat
I think the real problem is that you can’t register for something like “entry with watch-of property”. That’s what the hard-coded things in the endpoint do. You can only register for major objects (h-watch).
#
Zegnat
Note that this is all from reading the code, I still haven’t set-up Known.
#
Zegnat
That said, [cleverdevil], none of that is really obvious.
tantek and [kevinmarks] joined the channel
#
[cleverdevil]
Yeah, exactly.
#
pvagner
Guys is there a way to get twitter feeds into woodwind? Or another similar reader?
#
Loqi
pvagner: [jeremycherfas] left you a message 1 hour, 5 minutes ago: Yes, but core accepts a description if I type it in by hand. It is only when using Micropub or the Known API that it refuses to use description.
#
tantek
pvagner: check out Granary - that might do what you're looking for with Twitter
#
tantek
what is Granary
#
@rMdes_
@pvagner @withknown Amazing post, always wanted to understand how this was happening.. Thanks for the explanation :)
(twitter.com/_/status/956982941812391936)
[keithjgrant], tantek, [cleverdevil], [eddie] and [kevinmarks] joined the channel