-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some weird results #145
Comments
thanks for trying out bridgy fed and granary (more), and for filing all these issues! much appreciated. and apologies for the problems, obviously. you're right, granary does use mf2py, so it's often the root cause of mf2 parsing problems. it was dormant for a long time, but @kartikprabhu and @kevinmarks have recently picked up activity and done a lot of work on it in its new location, https://github.com/microformats/mf2py (and in https://github.com/kartikprabhu/mf2py/tree/experimental). i think they're getting close to putting out a release. looking forward to it! in general, for just parsing mf2 HTML to JSON, i'd recommend a normal mf2 parser. granary uses AS1 as its common backplane format, so everything goes through that first, which means it's sometimes lossy in ways that just mf2 HTML => JSON isn't. (not to mention requires an extra serial HTTP request if you're using https://granary.io/.) i'll still definitely look into the representative h-card name though! |
and thanks for filing the corresponding issue in mf2py! |
re the representative h-card name, https://pin13.net/mf2/?url=http://beta.singpolyma.net/ currently returns: "properties": {
"given-name": ["Stephen"],
"additional-name": ["Paul"],
"family-name": ["Weber"],
"name": ["singpolyma"],
"..."
...and granary takes that at face value, so it only keeps i'll update granary's mf2py as soon as @kartikprabhu / @kevinmarks cut a new release, which should hopefully fix the other issues. |
Oh, ok. So granary removes fields it can't convert to the intermediate format, that makes sense. And AS doesn't support the full-name properties. |
for snarfed/bridgy#828, #145, #142, etc.
fixes #142, fixes #145, fixes snarfed/bridgy#756, for snarfed/bridgy#828
i've tentatively upgraded mf2py to https://github.com/snarfed/mf2py/tree/all , in the mf2py branch here and deployed, which i think fixes the rest of these problems. |
the new output in https://granary.io/url?input=html&output=mf2-json&url=http%3A%2F%2Fbeta.singpolyma.net%2F and other examples here looks ok. definitely not as good as just a simple mf2 parser, but since html -> mf2 ison is an uncommon use case for granary, I'm ok with that. tentatively closing. feel free to reopen! |
https://granary.io/url?input=html&output=mf2-json&url=http%3A%2F%2Fbeta.singpolyma.net%2F
I see the first item is my representative hcard -- but it has as "author" property? Also not getting the full name that is present.
Authors on the hentries have the full content of the vcard as the
name
instead of pulling from thefn
property, and are also missing the full name that is present.Entries with
rel=tag
markup get adata
element appended to theircontent.html
property?For comparison, https://pin13.net/mf2/?url=http%3A%2F%2Fbeta.singpolyma.net%2F gives me what I expected. https://mf2.kylewm.com/?url=http%3A%2F%2Fbeta.singpolyma.net%2F&parser=html5lib has most of the same issues (I assume you also use mf2py, so that's probably it) but it at least handles the name in the representative hcard properly.
The text was updated successfully, but these errors were encountered: