#dev 2019-09-14

2019-09-14 UTC
KartikPrabhu and imsky joined the channel
#
aaronpk
jamietanna[m]: oh gosh, your website is sending webmentions to the wiki page https://indieweb.org/responses for every single post
#
aaronpk
which technically isn't wrong, and I should be filtering these out better since the link doesn't appear in the content of the post, but thought you might want to know
#
jacky
RIP lol
#
jacky
oh wow TIL that every wiki page is an h-entry too
#
@0xADADA
↩️ indieweb isn't walking to the VCs and selling out, but its actually building distributed and federated systems that work on community standards. Thats a HUGE win, but it takes time for it to coalesce https://0xadada.pub/2019/09/13/2307-webmention-reply/
(twitter.com/_/status/1172711639491198976)
nehtrtns^, gRegorLove and vika_nezrimaya joined the channel
#
vika_nezrimaya
this probably should be a very obvious question (and if it is not, documented on the wiki), but: can I guarantee that the me= URL that my app receives in the IndieAuth flow is the same URL on the h-card of a person I'm trying to authenticate?
#
vika_nezrimaya
if I need to know the URL in advance, e.g. for audience of private posts
#
vika_nezrimaya
s/can I/is there a/
#
jacky
!tell vika_nezrimaya nah - re: your question about the same URL. You'd have to look up the representative h-card of the URL you get (check the Wiki!) and use that h-card's URL as the canonical address
#
Loqi
Ok, I'll tell them that when I see them next
deathrow1 and KartikPrabhu joined the channel
#
jamietanna[m]
Aaronpk thanks for the heads up! Do you mean I need to tweak something on my side too, so they don't send as many?
#
jamietanna[m]
I decided to tweak it to "send webmentions to all the links on my site" after discussion in #dev this week
[tantek] and vika_nezrimaya joined the channel
#
vika_nezrimaya
!tell jacky thanks! That kinda should work I guess, and feels like a fool-proof way...
#
Loqi
Ok, I'll tell them that when I see them next
#
Loqi
vika_nezrimaya: jacky left you a message 2 hours, 22 minutes ago: nah - re: your question about the same URL. You'd have to look up the representative h-card of the URL you get (check the Wiki!) and use that h-card's URL as the canonical address
#
jacky
yeah I learned that the hard way tbh :)
#
jacky
hopefully I save you a few days of head ache :)
#
vika_nezrimaya
Probably months
#
vika_nezrimaya
but I have another problem now, and it's about architecture of my feed. Right now I have a key in Redis that lists posts for my main feed (it lists post ids and then posts are fetched with HMGET). For private feeds, I could go with several feeds or loading additional posts if some posts that were queued up for showing on the page can't be shown due to access restrictions...
#
vika_nezrimaya
but if I make several feeds (each one for an authenticated user) this could make filtering posts, e.g. by tag very difficult
#
vika_nezrimaya
should I switch databases or go with the second approach of checking post access rights on the feed loading and just throw it away if the user can't see it, loading another post in its place?
#
vika_nezrimaya
Redis is quick... >.<
#
jacky
SQLite is pretty fast too and gives you a lot of bang that other RDBMS have
#
jacky
I use it for https://v2.jacky.wtf and a lot of other projects
#
Loqi
Jacky Alciné
#
jacky
but to your question; it sounds like the feed construction is pretty complicated
#
jacky
and the design didn't leave a lot of food for manipulation / dynamic construction of feeds
#
vika_nezrimaya
It is. Currently it's just one key and post storage (which could be flat-files or another key in Redis)
#
vika_nezrimaya
And I want tag searches, and I want private posts
#
vika_nezrimaya
and the restriction is that I need to store posts in MF2-JSON, since that's what my renderer consumes
#
vika_nezrimaya
also it's kind of in the spirit of quick migration, since I could just feed JSON files one-by-one to another Micropub endpoint and fully recreate my blog's content
#
vika_nezrimaya
That's how I imported my posts to a new version of pyindieblog :3
#
jacky
So what I've done for my site (maybe you can crib this logic) is a two-fold approach: I store 'hot' values (post name, type, age) into SQLite and everything else into a file
#
jacky
I also have things like the relationship to tags, syndication target information and its visibility stored in the database so it can be queried too
#
vika_nezrimaya
Could I do something like intersecting sorted sets?
#
vika_nezrimaya
I'm not sure if Redis can do that
#
vika_nezrimaya
Basically feed construction can be generalized to intersecting sorted sets while preserving their order
#
vika_nezrimaya
i.e. intersect all posts that e.g. v2.jacky.wtf can see and posts tagged #indienews
#
jacky
I wouldn't know. This could also complicate your site setup and make it harder to grow/build/tweak
#
jacky
Not to dissuade you
#
vika_nezrimaya
It seems like Redis indeed can intersect sorted sets, but it's a bit complicated and requires a temporary key which values are then fetched...
#
vika_nezrimaya
ZINTERSTORE out 2 privatefeed_https://v2.jacky.wtf/ tagfeed_indieweb AGGREGATE MIN
#
vika_nezrimaya
assuming that in sorted sets, weight of an item correlates to its dt-published in Unix time
#
vika_nezrimaya
That'd be O(number of posts in the smallest set*number of sets intersected)+O(M*log(M)), where M is number of posts output as a result
#
vika_nezrimaya
feels slow
#
vika_nezrimaya
I think a SQL query will be faster
#
vika_nezrimaya
jacky: wow, SQLite can store JSON!
[pawel_madej] joined the channel
#
[pawel_madej]
YaY My webmentions are sent 😉 and brid.gy syndicated one test post to twitter :star-struck: but how in jekyll get back this tweet into post as syndication entry? Do i need to make it manually?
djmoch, [KevinMarks], [jgmac1106] and KartikPrabhu joined the channel
#
jamietanna[m]
For those who were interested in seeing the code I'd written for https://www.jvt.me/posts/2019/08/31/microformats-meetup/ I've just updated the post and linked through to the repo - https://gitlab.com/jamietanna/meetup-mf2
#
aaronpk
jamietanna[m]: I'd recommend sending webmentions only to the links that are actually part of the post content rather than literally all links on the page.
#
aaronpk
Again it's not technically wrong to send webmentions to everything including links in your footer and such, but it's a little bit overkill
#
aaronpk
Your site template includes a link to IndieWeb.org/responses in the footer, so sending a webmention there isn't really helpful or meaningful
#
aaronpk
Of course the trick with webmention is that anyone else could be sending a webmention from your site about that link which is why receivers should be handling this case better than I am right now
#
jamietanna[m]
Ah OK, that's fair! Would that mean putting u-syndication links in the h-entry or outside it? (so I can send webmentions to publish elsewhere)
#
sknebel
u-syndication links outside a mf2 root don't really make sense
gxt joined the channel
#
jamietanna[m]
True - I can't 100% remember if they're in or out, but I know when trying with mention.tech it didn't pick them up, even though they're parsed under the h-entry with php microformats.io
[jeremycherfas] joined the channel
#
sknebel
it's probably only looking at the content property of the h-entry
KartikPrabhu joined the channel
#
aaronpk
It's not even the syndication links I'm talking about
#
aaronpk
"Have you written a response to this post? Let me know the URL:"
#
aaronpk
"response" links to the wiki so the wiki got webmentions from every post
#
aaronpk
and that text is arguably not part of that particular post
#
aaronpk
On the receiving side, I should probably just ignore webmentions when the link isn't part of the mf2 "content" property, that would have stopped this flood on my end
#
sknebel
aaronpk: presumably, properties should count too?
#
aaronpk
Right now my webmention receiver just looks for the link at all, which is good for receiving webmentions from sites that don't use microformats. But I'm thinking if there are microformats on the source url then it should upgrade the check to the more strict check of looking for the URL in the mf2 data
#
vika_nezrimaya
Ok, my Micropub endpoint is timing out for some reason. It may be a faulty commit, but it's unlikely as it worked before!
#
aaronpk
that is weird, i haven't had nginx lock up like this before
#
aaronpk
should be back up now
#
vika_nezrimaya
Oh, you use nginx too? :3
#
jamietanna[m]
Hope I didn't contribute to it 😥
#
vika_nezrimaya
aaronpk: Aperture is back online! so is the wiki
#
aaronpk
jamietanna[m]: i doubt it
#
vika_nezrimaya
What's weird is... My site magically started working again too
#
jamietanna[m]
Vika_nezrimaya do you have some unknown dependency on Aaron's services maybe?
#
vika_nezrimaya
aaronpk: you're slowly becoming the center of the IndieWeb universe - nothing works without you :3
#
aaronpk
i hope not!
#
vika_nezrimaya
jamietanna, I shouldn't. Micropub endpoint (the faulty part) makes NO external requests (except to the token endpo-WAIT
#
vika_nezrimaya
aaronpk do you maintain token.indieauth.com?
#
aaronpk
haha yes
#
vika_nezrimaya
Ok
#
vika_nezrimaya
That explains everything
#
aaronpk
that's an easy one to run yourself though
#
vika_nezrimaya
I know, still haven't gotten around to rewrite my old IndieAuth code
#
vika_nezrimaya
Indeed it's a SPOA here
#
vika_nezrimaya
Yay, I can post stuff again :3
#
Loqi
😃
ben_thatmustbeme joined the channel
#
GWG
I don't depend on aaronpk, do I?
#
GWG
Well, maybe oys, but I could give that up
[jgmac1106], gxt and [schmarty] joined the channel
#
jgmac1106
jeremycharfas I had to switch to grid from flex but I move the e-content inside the figcaption which also means I can lose a div and move the h-entry back to the figre element : http://jgregorymcverry.com/oceancity2019.html
#
jgmac1106
did gain a span so number of elements didn’t change but always feels good to lose a div
#
jgmac1106
subgrid is gonna be awesome for photo layouts combined with text, makes me wonder if I can do an overlay and a CSS timer to make text overlays on video accessible
nfip^ joined the channel
#
jacky
so I'm going to work on Lwa for a little bit
#
jacky
and the client aspect of it is already leveraging WebSockets for handling the interface
#
jacky
it's very nice but I haven't made it work with a random / another client (it's tied in heavily with Lwa itself)
#
jacky
which I guess doesn't make it a true microsub client
#
jgmac1106
good luck jacky
#
jacky
😤😤😤
#
jgmac1106
do CSS animation and Grid not work the same on Safari? I use the dev mobile preview tools but then I look on my partner’s phone and the images are not the same and I get no hover state
thefirstrealm and [KevinMarks] joined the channel
vika_nezrimaya joined the channel
#
vika_nezrimaya
https://micropub.rocks/server-tests/204?endpoint=408 - I know I passed this test because when my endpoint tried to render the post, it crashed, not expecting lat/lon as properties instead of an h-geo. Should be fixed in the next commit :3
[fluffy] and gRegorLove joined the channel
#
jeremycherfas
Wondering why you feel losing a div feels good, jgmac1106 ? Since embracing Tailwind I’m loving how easy responsive is with as many divs as I need.
#
jeremycherfas
Hover is unreliable on phones.
#
jacky
yeah it's a non-state imo
#
jacky
unless we get sensors that can emulate hover
#
jacky
does anyone use a image proxy for their site?
#
jacky
I store images on my own site but if it's external, I directly point out
#
jacky
I'm considering it because there's little things I point to (Quill's logo for one) and it's probably just mad referrer headers showing what page it was on that called it
#
jacky
oh man
#
jacky
my h-feed is broken
#
vika_nezrimaya
jacky: oh, I'm planning on getting an image proxy
#
vika_nezrimaya
maybe together with a media endpoint
#
vika_nezrimaya
also considering outsourcing it to Amazon S3 or GCE but not sure if it'll fit within the constraints of the free tier
#
vika_nezrimaya
I don't wanna pay
#
vika_nezrimaya
I'm a cheapskate girl but I don't want to host it if possible, Amazon or GCE have more bandwidth than me :3
#
jacky
that's valid
#
jacky
how much bandwidth do you think you'll use?
#
jacky
and with proper caching headers, you should be okay!
#
vika_nezrimaya
Well, almost nobody reads me
#
jacky
then you'll be fine :)
#
vika_nezrimaya
I think aaronpk reads me, maybe people who I usually send webmentions to subscribe to me
#
vika_nezrimaya
I'm not sure, there's no easy way to check who reads you
#
jacky
not yet
#
vika_nezrimaya
nobody publishes u-follow-of posts
#
jacky
you can peek by looking at your web traffic though
#
jacky
in your web logs
#
jacky
actually no you couldn't
#
jacky
I was thinking referrer information
#
vika_nezrimaya
it's all IP addresses and weird stuff
#
jacky
yeah lol
#
vika_nezrimaya
I'm too dumb to read it
#
vika_nezrimaya
I'm just a girl, not a GeoIP database mapping people to their home addresses
#
vika_nezrimaya
being trans or a girl doesn't give me superpowers :c
#
jacky
not yet!!
#
vika_nezrimaya
I wish I could write bug-free code
#
jacky
but this is something that I _think_ can be pulled from hubs
#
vika_nezrimaya
Well, I'm writing tests that don't allow me to write bug-free code
#
vika_nezrimaya
jacky: I think so
#
vika_nezrimaya
but Aperture (#SPOA) doesn't use hubs!
#
[schmarty]
i use cloudinary as an image proxy
#
[schmarty]
(also for thumbnailing)
#
jacky
it doesn't - it uses Watchtower ;)
#
vika_nezrimaya
or actually it's Watchtower that doesn't
#
jacky
[schmarty]: that's smart - my site is currently handling it
#
vika_nezrimaya
but it's kinda part of Aperture so who cares except for aaronpk maybe
#
jacky
IIRC Watchtower supports WebSub and does work to manually check pages for changes
#
vika_nezrimaya
last time I asked, it didn't
#
vika_nezrimaya
but it was around a year ago maybe?
#
jacky
maybe! I also was just pursuing the other day so I don't know
#
vika_nezrimaya
Wow, seems like something new
#
vika_nezrimaya
I wish I could use a Docker container with my own Aperture instance >.<
#
vika_nezrimaya
I want something in-between the "host it yourself" and "set a few URLs and forget about it unless something breaks"
#
jacky
you know I thought the same
#
jacky
how do you deploy your site?
#
jacky
I use Dokku so I can bounce between Docker and buildpack-driven deployment
#
jacky
the latter is faster requires less optimization on my behalf tbh
#
jacky
the former low-key takes a day and leads to thick images
#
jacky
like I do like the 'one command to get it running' nature of Docker
#
jacky
but the tradeoffs kinda suck
#
vika_nezrimaya
jacky: nixops!
#
vika_nezrimaya
I have my software packaged with Nix, deployed on a NixOS machine (currently an old laptop)
#
vika_nezrimaya
I use a following forkflow: cd software/pyindieblog && git pull && cd .. && nixops modify deployments/home.nix && nixops deploy
#
vika_nezrimaya
i.e. update the pyindieblog from git, register the new configuration of my home network and proceed with deployment
#
vika_nezrimaya
I'm not sure if my NixOps configuration is public though...
#
vika_nezrimaya
but the pyindieblog bits are public
#
vika_nezrimaya
configuration.nix file is what you need to import to set this thing up :3
#
vika_nezrimaya
requires some proficiency with nginx/apache/lighttpd and NixOS
#
vika_nezrimaya
I use Nginx
#
vika_nezrimaya
Wanted to try something new after lighttpd...
#
jacky
this reminds me of terraform a bit
#
vika_nezrimaya
never used it
#
vika_nezrimaya
NixOps is the first deployment and DevOps tool I've ever used in my life.
#
vika_nezrimaya
I also use a single Docker container for Gotify (which turned out to be harder than usual to package)
#
vika_nezrimaya
That docker container is provisioned by NixOps and NixOS too btw
#
jacky
perhaps making a nix overlay(?) for a generic PHP/laravel project and applying that to your own repo of projects for aaron's stuff?
#
jacky
upside about most of his stuff is that deployment-wise, it's not like _tied_ to a provider
krychu and [jgmac1106] joined the channel
#
[jgmac1106]
Getting closer on mobile had the opacity backwards on hover. http://jgregorymcverry.com/oceancity2019.html
#
[jgmac1106]
Need to resize text in caption
nfip^ left the channel
#
jamietanna[m]
I should have resolved my post deploy webmentions - deploy is going through now so we should know shortly!
gRegorLove joined the channel
#
jacky
jamietanna[m]++
#
Loqi
jamietanna[m] has 4 karma in this channel over the last year (9 in all channels)
#
jacky
[jgmac1106]++
#
Loqi
[jgmac1106] has 12 karma in this channel over the last year (115 in all channels)
jjuran and [fluffy] joined the channel
#
[fluffy]
[schmarty] it looks like there’s a bunch of sites on the indieweb webring that don’t actually have visible webrings on the linked pages, which breaks the ring. Any way that could be better-enforced?
#
jacky
lol and I wiped out my stream now