#microformats 2018-03-21

2018-03-21 UTC
tantek joined the channel
#
tantek
thanks KartikPrabhu
[eddie], ben_thatmustbeme, [miklb], [kevinmarks] and tantek joined the channel
#
@gumnos
@TallBlondeGuy @IgnoreIntuition @AlexCastroR12 @ThePracticalDev Bits of it have grown up in select areas. Google's crawler used to (still does?) identify certain taggings and microformats for things like prices, ratings, contact information, etc. But it is indeed a languishing area. https://en.wikipedia.org/wiki/Microformat
(twitter.com/_/status/976288351664967680)
#
aaronpk
wow, i have never seen "microformat" used in the singular
#
@overcaffeinated
@RodBegbie @waferbaby ... at about this time there was a lot of noise about microformats *replacing* RSS! Ohboy we all had a good laugh about that! As Tantek would say: these ideas are not contrary to each other! Fun times. But then came Atom, and don’t get me started!...
(twitter.com/_/status/976303007087259649)
#
aaronpk
oh dear
#
KartikPrabhu
fight fight fight
#
tantek
wait which side am I on? lol
#
KartikPrabhu
tantek: you can referee if you'd like ;)
#
tantek
looking now for the blog posts that mention many things
#
tantek
there was one recently
#
Loqi
[Eli Mellen] A year with the IndieWeb
KartikPrabhu and tantek joined the channel
#
@t
@overcaffeinated @RodBegbie @waferbaby #indieweb folks choose that which meets needs eg: https://eli.li/entry.php?id=20180314144847 #IndieAuth #Micropub #Webmention #RSS #Microformats and https://twitter.com/ChrisAldrich/status/961794239163068416. My site #hfeed #Atom. Simple building blocks enable ... http://tantek.com/t4tW5
(twitter.com/_/status/976339994121039872)
#
tantek
hows that aaronpk, KartikPrabhu ?
#
KartikPrabhu
we'll see how the fight goes ;)
#
tantek
who's fighting? :)
#
KartikPrabhu
no one's fighting? boooooooooring :P
#
tantek
edited /microformats2-parsing (+155) "edits which complete resolution of issues #31, #30, #29, #28. consensus on all including 2+ implementers, and each have been prototyped in mf2py"
(view diff)
#
tantek
if that looks good, I'll leave it to the issue filers to confirm that reflects their need and the issue resolution, and close the individual issues accordingly
#
KartikPrabhu
ooo 1+ vendor prefixes!
#
KartikPrabhu
so h-p3k-p6k-entry is allowed?
#
tantek
did I typo that
#
tantek
hah no re-read :P
#
KartikPrabhu
the current mf2py implmentation allows exactly 1 vendor prefix
#
tantek
series of 1+ lowercase a-z or numbers
#
tantek
i.e. <code>[0-9a-z]+</code>
#
tantek
followed by '-'
#
tantek
so that spec language also only allows one vendor prefix
#
tantek
all of which is parenthetical inside *an optional vendor prefix*
#
tantek
so not sure how you can misread that as "1+ vendor prefixes"
#
KartikPrabhu
i read that as "1+, lowercase or numbers"
#
KartikPrabhu
so 1+ meaning one or more
#
KartikPrabhu
but you are right
#
KartikPrabhu
that looks good to me
gRegorLove and [unoabraham] joined the channel
#
Zegnat
Ah did stuff get resolved?! Can't wait to review!
#
KartikPrabhu
Zegnat : yes review and also close the issues if resolved
#
Zegnat
As soon as my morning tea is at my side. Having a hard time getting started today
#
tantek
edited /microformats2-parsing (+9) "reword slightly to indicate 1+ characters, not prefixes"
(view diff)
#
tantek
KartikPrabhu: ^^^ does that help?
#
tantek
Zegnat, issues 28-31
#
tantek
you have a few minutes to review the spec edits before I go to sleep :)
#
KartikPrabhu
tantek: now I can't read it wrong in my head :P
#
Zegnat
I should get a bedside computer to check things. Almost on GitHub now. Tea in hand.
#
Loqi
definitely
#
Zegnat
Is there a reason we keep source order for rels?
#
Zegnat
tantek ^^^
#
KartikPrabhu
for the actual urls that seems fine
#
KartikPrabhu
for example if you want to pick the first URL that has a rel=author
#
Zegnat
I mean the specific `rels` array
#
Zegnat
Nested under a URL
#
KartikPrabhu
is that doc ordered?
#
Zegnat
unless “unioning” sets somehow changes order, yes
#
Zegnat
“set the value of that "rels" key to an array of all unique items in the set of rel values unioned with the current array value of the "rels" key”
#
Zegnat
That does keep them in source order by my reading
#
KartikPrabhu
set is unordered
#
KartikPrabhu
no "source order" is specified
nitot joined the channel
#
Zegnat
that’s deceptive, because HTML parsers stick to source order for sets. Also as we said, we can’t have unordered output as all JSON output is ordered.
#
tantek
the array of URLs for a rel is deliberately ordered yes because each of those is from a different element, which has document source order semantics
#
Zegnat
Yes, but I am talking about the `rels`array, which only contains the rel values per URL, tantek
#
KartikPrabhu
Zegnat: tantek is saying that those have doc order semantics too
#
KartikPrabhu
the first rel specified for a given URL
#
KartikPrabhu
in the doc
#
Zegnat
Surely <a href="#" rel="me bookmark"></a> and <a href="#" rel="bookmark me"></a> should result in the same thing?
#
KartikPrabhu
they will
#
Zegnat
Currently those two things parse differently, I believe
#
Zegnat
because the array in ["rel-urls"]["#"]["rels"] will keep source order
#
Zegnat
So the first will be ["me", "bookmark"], and the second ["bookmark", "me"].
#
KartikPrabhu
no! Zegnat
#
KartikPrabhu
but <a rel="bookmark" href="example"> <a rel="me" href="example"> is different from the reverse doc order
#
tantek
ah I see the detail you're referring to I think
#
KartikPrabhu
first one gives a ['bookmark', 'me'] while the second gives reverse order
#
Zegnat
It isn’t in the rels array ... the rels array (nested under "example") should only tell you what relation that URL has to the current doc
#
tantek
KartikPrabhu: in that case the order doesn't matter
#
Zegnat
and that relation doesn’t change with multiple A elements spread throughout the source
#
Zegnat
That’s why my issue was about the type *and* rels array
#
tantek
just the last step of rel parsing needs a minor adjustment
#
tantek
Zegnat, remind me issue # rather than "my issue"? you filed a few :)
#
Zegnat
And there is only one rels array, specifically ["rel-urls"][$url]["rels"]. I am not talking about all arrays that have to do with rel parsing
#
Loqi
[Zegnat] #29 Define the order of items any time an array is used in the parsed output.
#
tantek
yeah just missed it
#
tantek
editing
#
KartikPrabhu
hmm ok will think about it for mf2py tomorrow
#
tantek
it's last step of rel parsing
#
Zegnat
yep, last step of rel parsing unions all sets together, but it never specifies an order for the resulting array (and we need order because JSON)
#
tantek
on it
#
Zegnat
Otherwise, change for vendor prefix support looks good, alphabetical sorting change on types looks good too
#
tantek
edited /microformats2-parsing (+24) "rels array for a particular URL should also be sorted alphabetically to remove any artificial ordering, part of issue #29"
(view diff)
#
tantek
thanks for the review
#
Loqi
[Tantek Çelik] microformats2 parsing specification
#
Zegnat
LGTM tantek!
#
Zegnat
tantek++
#
Loqi
tantek has 14 karma in this channel (425 overall)
#
Zegnat
KartikPrabhu++
#
Loqi
kartikprabhu has 19 karma in this channel (186 overall)
#
Zegnat
gRegorLove++
#
Loqi
gregorlove has 25 karma in this channel (225 overall)
#
Zegnat
Thanks for all the quick iterating! Now I can finally *close* some issues instead of just opening them :D
#
tantek
yay that should at least fix a few things
#
Loqi
does a happy dance!
#
tantek
hopefully that enables new releases of parsers? or are we still waiting on spec issues for parser releases?
#
tantek
I know the vendor prefix one was affecting aaronpk
#
KartikPrabhu
mf2py release is currently stuck on ownership on the python package thing
#
Zegnat
tantek, if you haven’t headed for bed yet, could you please close https://github.com/microformats/microformats2-parsing/issues/28 ? I can’t, because that wasn’t one I opened
#
Loqi
[gRegorLove] #28 Allow numbers in vendor prefixes
#
Zegnat
should petition for access to the parsing repo
#
tantek
I'll leave it to gRegorLove if he's satisfied :)
#
Zegnat
All the others have now been closed with links to the spec updates
#
Zegnat
Just in time too, running low on tea again.
#
Zegnat
stumbles of to find breakfast and more tea
gomarota, [pfefferle], [unoabraham], nitot, nitot_, [kevinmarks] and webchat129 joined the channel; webchat129 left the channel
#
parlaybola
edited /get-started () "(-3627)"
(view diff)
#
dagototo
edited /get-started () "(-3226)"
(view diff)
#
sknebel
Zegnat: do that again^^^
barpthewire, Garbee and [kevinmarks] joined the channel
#
[kevinmarks]
Html5lib has a "sort attributes" option - they are normally in arbitrary order. Not sure about spaces separated values in attributes
[adamrice] joined the channel
#
Zegnat
html5lib is right to stick to source order, that’s what WHATWG defines for most of these things.
#
zegnat
edited /get-started (+3226) "Undo revision 66727 by [[Special:Contributions/Dagototo|Dagototo]] ([[User talk:Dagototo|Talk]]) - spam"
(view diff)
#
Zegnat
Hahahaha, that was the best recaptcha I ever had to do
#
Loqi
rofl
#
Zegnat
And yes, that let me post
#
sknebel
we'll se what happens in 10 days...
[kevinmarks] joined the channel
#
[kevinmarks]
if you parse with html5lib and output html again, the attributes will likely change order
#
Zegnat
[kevinmarks], hmm, that sounds almost like a bug. I seem to recall the HTML parsing algo specifically keeping source order when converting to the DOM tree against that
#
Zegnat
But I might be misremembering
nitot, [cb], [pfefferle], [adamrice], chrisaldrich, [chrisaldrich], [eddie], tantek, KartikPrabhu and gRegorLove joined the channel
#
Zegnat
tantek, who do we show this screenshot to to get the microformats wiki updated? https://i.imgur.com/0QgqxV6.png
#
tantek
so what happens when it shuts down?
#
tantek
KartikPrabhu: not helpful
#
KartikPrabhu
I am guessing you edits are no longer going to work
#
Zegnat
Or this is going to displayed then still
#
Zegnat
Note that I was able to edit by writing the shutdown text in the field.
#
Zegnat
If that stays the same, bots will just always enter that and you will have no protection from the captcha
#
Zegnat
Oh. “Any calls to the v1 API will not work after March 31, 2018.” So I guess it isn’t going to allow anything to go through anymore?
#
KartikPrabhu
Zegnat: yeah that ia my guess. nothing goes through
#
tantek
so no new external links?
#
tantek
that'll block the little spam we get now ;)
#
Zegnat
If that’s the only thing that triggers it.
#
Zegnat
Or does it also trigger if there are external links on the page you want to edit?
#
tantek
*new* links
#
tantek
read the microcopy
#
tantek
in your own screenshot :P
#
Zegnat
Alright. I guess the spam reverts I do count as new links because they aren’t in the latest version of the page
[cleverdevil], tantek and [adamrice] joined the channel
#
gRegorLove
aaronpk, Did you change your vendor prefix to "pk"? Any URLs with "p3k" examples?
#
aaronpk
I changed them to pk- because I couldn't parse my own site!
#
aaronpk
I'll change them back once the parser is updated and released tho
#
gRegorLove
Understood, just checking if there was an example I could put in the issue. I'm working on the fix for php-mf2 :)
#
gRegorLove
I'll make a simple one based on your markup
#
aaronpk
you could use a web.archive.org link from one of those pages 😂
#
gRegorLove
Oh yeah, heh
#
gRegorLove
php.microformats.io needs to be updated to latest php-mf2
tantek joined the channel
#
KartikPrabhu
oops should update those for hyphen checks
#
KartikPrabhu
does that while waiting for DNS propagation
#
gRegorLove
Issues filed for php-mf2. Will work on vendor prefix PR later today.
#
tantek
gRegorLove++ great!
#
Loqi
gregorlove has 26 karma in this channel (226 overall)
#
gRegorLove
Are there examples of php-mf2 returning incorrect ordering per https://github.com/microformats/microformats2-parsing/issues/29?
#
Loqi
[Zegnat] #29 Define the order of items any time an array is used in the parsed output.
#
KartikPrabhu
gRegorLove: my test example also does that :)
#
KartikPrabhu
so you could run it
#
Zegnat
gRegorLove, not for type, I think, that’s always alphabetical in php-mf2. I am actually not sure about rel.
#
KartikPrabhu
example of both order and duplication
#
gRegorLove
Should the expected output here be updated? Sorry, I'm still having a hard time wrapping my mind around expected output for 'rels': http://microformats.org/wiki/microformats2-parsing#rel_parse_examples
#
Loqi
[Tantek Çelik] microformats2 parsing specification
#
KartikPrabhu
gRegorLove: no that expected output is correct
#
gRegorLove
Nevermind, I get it on re-reading
#
KartikPrabhu
see my example test above which has rel="boodongle alternate boodongle" that should give ['alternate', 'boodongle'] as output
#
Zegnat
gRegorLove, when I look at ["rel-urls"]["#"]["rels"] there it is neither alphabetically sorted, nor is it the union of all rels for that URL ("me" is missing) - http://pin13.net/mf2/?id=20180321182735137
#
Zegnat
Putting that same HTML in the Python dev one, the union is right, but rels aren’t alphabetically sorted either
#
gRegorLove
Hang on, only looking at `rels` for the moment.
#
KartikPrabhu
Zegnat: hmmm
#
gRegorLove
In this example, the two URLs should be sorted alphabetically under rels.author, right? http://pin13.net/mf2/?id=20180321182848652
#
KartikPrabhu
aah I see. I am doing sorting only on each element, but this one is global will fix
#
KartikPrabhu
gRegorLove: no!
#
KartikPrabhu
only the rels in rel-urls
#
gRegorLove
"set the value of that "rels" key to an array of all unique items in the set of rel values unioned with the current array value of the "rels" key, sorted alphabetically.
#
KartikPrabhu
right. not individual "author" properties
#
KartikPrabhu
gRegorLove: read that as rels-urls > someurl > rels is the sorted one
#
gRegorLove
I'm not even talking about `rel-urls`
#
KartikPrabhu
then that output is correct the URLs are not to be sorted only the rel keys
#
Zegnat
Yes, looks like that HTML gets parsed completely correct gRegorLove
#
@t
hosting Homebrew Website Club SF tonight @MozSF! RSVP http://tantek.com/2018/080/e1 Special guest @aaronpk will demo his #IndieWeb reader setup! https://aaronparecki.com/2018/03/12/17/building-an-indieweb-reader built on #openweb standards #WebSub #Microsub #microformats2 #IndieAuth #MicroPub ... http://tantek.com/t4tX1
(twitter.com/_/status/976527420189761536)
#
Zegnat
and yes KartikPrabhu, it is a sort after union :)
#
KartikPrabhu
Zegnat: yeah I missed that one :)
#
Zegnat
Feel free to use that snippet of HTML as a test. Should test both sorting and unioning.
#
Zegnat
Should create: "rel-urls": { "#": { "rels": [ "archived", "bookmark", "me" ] } }
#
gRegorLove
Ok, my confusion here is because I'm talking about the `rels` at the same level as `items` in the parse, not rel-urls > rels
#
gRegorLove
Based on my reading, this is the ordering I would expect for the wiki example: https://gist.github.com/gRegorLove/3e917691323efc4073a0eb1b081cab41
#
Zegnat
All the orders there should be in source order. If the spec says otherwise that needs an issue. My sorting issue was only about rel-urls > rels
#
Zegnat
You are talking about step 4.2, where you should just “add url to the array” (to the end is implied).
#
gRegorLove
No wonder I haven't followed any of this. :)
#
Zegnat
Sorting alphabetically only applies on step 9
#
gRegorLove
issue 29 doesn't have `rel-urls` anywhere.
#
Zegnat
There is only 1 rels array in the spec
#
Zegnat
the other rels is an object
#
Zegnat
But yes, definitely confusing
#
Zegnat
My mistake
#
gRegorLove
Step 9 is still where my confusion lies
#
Zegnat
Step 9 is about rel-urls > rels though
#
Zegnat
Everything after step 5 is about rel-urls and its properties
#
gRegorLove
Okay, I'll have to re-read later with fresh eyes.
#
gRegorLove
If there's an issue with php-mf2 on this, issues welcomed.
#
gRegorLove
*github issues welcomed
#
Zegnat
I had to read it multiple times to catch on to that too. Maybe we can figure out a better way to write the rel parsing algo
#
gRegorLove
I must have understood it at some point since I worked on rel-urls in phpmf2, haha
#
Loqi
gRegorLove: lol
[kevinmarks], [eddie], [miklb], [cleverdevil], [pfefferle], wolf and tantek joined the channel
#
KartikPrabhu
ok mf2py experimental should be updated with ordering the rel-urls > rels
#
KartikPrabhu
needs to optimise that a lot of sorting is going on in the middle steps
[miklb], webchat140 and [kevinmarks] joined the channel; webchat140 left the channel
#
[kevinmarks]
Probably not that significant as there are only ever a few rels
[unoabraham] and KartikPrabhu joined the channel