I just read this blog post (%25gWpOwxNMoi%2FIkX5xJiNbSUEfwyjDKrMuvRLRF08mBWo%3D.sha256) which is an ssb message of type blog.
First, I was surprised that patchwork actually handles this! :+1:
I liked the message, then went on to do other things, then remembered I wanted to share the ID with a friend, but it doesn't seem to show up on my "Profile" page, while other votes do.
I'd expect the blog post to show up with the nice summary card as in the search results:

My intuition is that this is handled in modules/message/html/render/vote.js, messages look like this:
{
"previous": "%1pb+pdobatGXIpSnYGxVKkBlbex7qRXzZuLywHYr2W4=.sha256",
"sequence": 9668,
"author": "@+oaWWDs8g73EZFUMfW37R/ULtFEjwKN/DczvdYihjbU=.ed25519",
"timestamp": 1554994025781,
"hash": "sha256",
"content": {
"type": "vote",
"channel": "festival",
"vote": {
"link": "%gWpOwxNMoi/IkX5xJiNbSUEfwyjDKrMuvRLRF08mBWo=.sha256",
"value": 1,
"expression": "Like"
}
},
"signature": "WkCtwBLYAafpvArjrC9RU4oE7PyNyTnQ+dMZK5K7YPD0+3/4S513Jbwb0b+YXJJySdYqMwjrt5U0KpF78hcnAA==.sig.ed25519"
}
Removing blocking as this seems to already be in 3.11.6.
much as I like the blog format, I agree.
So I came back here because I just realized blog messages are being treated weirdly all over the place. It's not quite clear to me when/where they are or are not displayed.
@Irma Pince just published a whole series of blog type messages, yet her profile looks like this for me even though I'm following her:

Not sure if that's a separate issue or just another way this one shows itself.
Just tested on the latest master. Same results.
The blogs do show up in the Public section, and in the channel they were posted in.
So I'm going through the code to render profiles:
https://github.com/ssbc/patchwork/blob/master/modules/page/html/render/profile.js#L234
var feedView = api.feed.html.rollup(getStream, {
prepend,
hidden: contact.hidden,
compactFilter: (msg) => msg.value.author !== id, // show root context messages smaller
ungroupFilter: (msg) => msg.value.author !== id,
updateStream: api.sbot.pull.stream(sbot => sbot.patchwork.profile.latest({ id }))
})
which I tried emulating from the terminal with this call:
$ sbot patchwork.profile.roots --id '@aSo64imXSBLAruX2ZAZ1E8BSQidEUsvp2Lziiu3youY=.ed25519' | jq .value.content.type
"about"
"about"
"contact"
"contact"
"blog"
"contact"
The one blog message is the one visible in the screenshot above. So I guess that puts the problem somewhere into ssb-server? Because the feedView can then only select a subset of what ssb-server retrieves, right?
Hmm, I think that's using this code: https://github.com/ssbc/patchwork/blob/6eca826035715b715e67096aa87cc7a7ea9107a2/lib/lookup-roots.js
Which is using this: https://github.com/ssbc/patchwork/blob/6eca826035715b715e67096aa87cc7a7ea9107a2/lib/get-root.js
Which looks like it requires a root property on the message. Do blog messages have that? If not, maybe they're getting handled weirdly? Or maybe I'm barking up the wrong tree entirely...
Thanks for the pointer @christianbundy!
It doesn't seem to be a problem of getRoot() since that only retrieves a root if one exists and getRootMsg() simply iterates until no root is found. So for a blog to not have a root is fine.
But from what I understand, the blog messages actually never even get passed into LookupRoots() when opening the profile page. They do get passed though when opening e.g. #archival or #welcome-to-night-vale. I simply put a console.log() in there for every blog type message, and I don't get output when opening Irma's profile page.
So if I understand this correctly, when opening the profile the calls are about this:
patchwork.profile.roots() > ssb.createUserStream() > LookupRoots().
And somehow the blogs get lost before they make it to the last one. Not sure where ssb.createUserStream() is really defined.
Ah, and since I'm looking into this: blog type messages seem to generally not have a root property, but simply because the UI doesn't seem to allow that. At least I didn't see that in patchwork or patchbay and not even in ticktack (although there I might have missed it).
So I'd handle blog messages just like regular posts: if they have a root, return that. If they don't, consider them a root themselves.
This is not just hypothetical by the way. Some blogs do have a root property:
$ sbot messagesByType --type blog | jq '{"author": .value.author, "key": .key, "root": .value.content.root, "blog": .value.content.blog} | select(.root | .)'
{
"author": "@p13zSAiOpguI9nsawkGijsnMfWmFd5rlUNpzekEE+vI=.ed25519",
"key": "%Kly5qANVcTkqLLoS1f9xClbPjn3EYMoMpaqPFK1WqtE=.sha256",
"root": "%kh/kXkert3x/6BcHf0JIVAlos26AUnkoBg9Rkoqivwc=.sha256",
"blog": "&Ff2mX03ejv+40bgXsCWH5/1cDCIdPajj+B0RJATk8mE=.sha256"
}
{
"author": "@p13zSAiOpguI9nsawkGijsnMfWmFd5rlUNpzekEE+vI=.ed25519",
"key": "%WSfYoQZLrB0oDhW5rc8lZxmApOgG18Fo81D4DWx9cXU=.sha256",
"root": "%q8o5B8Gn99LCDePDDXd5S6ss4eAf5+luiXhm55cQQo4=.sha256",
"blog": "&Ff2mX03ejv+40bgXsCWH5/1cDCIdPajj+B0RJATk8mE=.sha256"
}
{
"author": "@MRiJ+CvDnD9ZjqunY1oy6tsk0IdbMDC4Q3tTC8riS3s=.ed25519",
"key": "%FFqJGm8LBd2xiz2sqFUVwb67vUGzaDPY9sW/qirhS9I=.sha256",
"root": "%zimjUyf0hlwO0dBTHCJFmiOHrrCRn77ENKE0gRaQkbg=.sha256",
"blog": "&7/LxY4cFKIXmAU+Xyle3rYr26hoK5oMF1JjDQfA4Sho=.sha256"
}
That last one there is actually a command line experiment of my own from a while back. But the others are genuine blog type replies by cryptix to other posts. Incidentally they share the content blob.
So I guess treating blogs like regular posts in this regard seems valid, even if we don't have the UI to actually do that. Yet. :P
Time for bed for me. Cya all tomorrow :)
Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?
Still very much relevant, and since it's clearly a bug in an existing feature ("display blog type messages) I think it's also in scope.