#dev 2020-12-24

2020-12-24 UTC
[tantek] joined the channel
#
[tantek]
gRegorLove++ definitely counts!
#
Loqi
gRegorLove has 11 karma in this channel over the last year (54 in all channels)
#
[tantek]
give it a version number
#
gRegorLove
? it has one
lahacker, maxwelljoslyn, KartikPrabhu, jeremy, voxpelli and [tantek] joined the channel
#
[tantek]
Just saw, I should’ve clicked on the link rather than judging from it ;) https://github.com/gRegorLove/mf2-to-iCalendar#003
#
Loqi
[gRegorLove] mf2-to-iCalendar: Convert microformats h-event to iCalendar
kitt, craftyphotons__, [chrisaldrich], shoesNsocks, dhanesh, schmudde and deathrow1 joined the channel
#
@AndreJaenisch
Interesting! A Gregor (https://gregorlove.com/) wrote a #Webmention plugin for #ProcessWire :o
(twitter.com/_/status/1342074954729320450)
#
@AndreJaenisch
↩️ If you want to try it out, I'd suggest looking into https://webmention.io/ and/or https://brid.gy/
(twitter.com/_/status/1342079687636488192)
#
@AndreJaenisch
↩️ If you want to try it out, I'd suggest looking into https://webmention.io/ and/or https://brid.gy/
(twitter.com/_/status/1342079687636488192)
#
@autiomaa
↩️ Some historical information about Webmention https://indieweb.org/Webmention from people who created it.
(twitter.com/_/status/1342081324530757632)
[jeremycherfas], geoffo and [Raphael_Luckom] joined the channel
#
[Raphael_Luckom]
@vilhalmer (preemptively relocating to dev) yeah, arrow functions are nice. I like object destructuring as well. `const` and `let` are marginally nicer than `var`.
#
vilhalmer
all languages eventually coalasce to the same set of features haha
#
vilhalmer
proper destructuring is nice
#
[Raphael_Luckom]
My highest aspiration for JS has always been "a usable lisp" and it was perfect for that early on
#
[Raphael_Luckom]
I'm pretty sure that no amount of new features can erase that, so I use the couple of things I like and avoid the stuff I don't
#
vilhalmer
part of the problem with languages that evolve like this instead of being designed with things up front is that there are eventually so many disparate toolsets
#
vilhalmer
python has the same issue
#
vilhalmer
but it's hard to avoid because languages that are designed all at once and languages that are used by a lot of people are nearly disparate sets
#
vilhalmer
js has native async syntax now too right?
#
[Raphael_Luckom]
yeah...one of the really interesting things about js is how it demonstrates that having a widely-available runtime might be a better predictor of language success than "whether people like the language"
#
[Raphael_Luckom]
it does, for promises
#
vilhalmer
that's an interesting point
#
vilhalmer
history indicates that people like to target cross-platform things
#
vilhalmer
despite them almost always being worse on any given platform than a native tool
schmudde joined the channel
#
vilhalmer
it makes sense though, everyone has limited resources to dump into development
#
[Raphael_Luckom]
I love JS the language (accepting that many don't, not my fight). I used to get kinda snippy about the stuff that I thought were mistakes (promises, typescript) but when I realized that those things, by focusing on transpilation, were actually cementing the presence of native JS runtimes on every platform ever, I decided to not interrupt my opponents while they were making a mistake 🙂
#
vilhalmer
python async has been interesting to watch evolve because it's by design a completely separate language that just happens to share the same interpreter
#
vilhalmer
it really should have been a new language
#
[Raphael_Luckom]
oh interesting, I haven't looked at that yet
#
vilhalmer
async and traditional python very nearly don't coexist in a given project, it's a lot of work to bridge them
#
vilhalmer
so there are now two library ecosystems
#
vilhalmer
I can't imagine coming into it new now
#
vilhalmer
(and that's putting aside the debate about whether async was even well designed, I have no opinion on that since I haven't used it in other languages)
#
vilhalmer
probably should have stayed in chat lol this is not very indie or web
#
[Raphael_Luckom]
approaches to async are fascinating. there's this tension between "doing stuff in the background lets you parallelize stuff" and "it's hard to think about things outside an imperative-looking context"
#
vilhalmer
yeah I think it's largely an unsolved programmer UX problem
#
vilhalmer
we know there are benefits but they come at a large cost
[snarfed] joined the channel
#
[snarfed]
eh erlang led to good work there, both go with goroutines/channels and modern JS’s async/await provide usable, scalable concurrency in imperative looking code
#
[snarfed]
no callback hell
#
vilhalmer
I have to re-learn async thinking every time I try to use it because I don't get to spend any significant time there
#
[Raphael_Luckom]
true, no callback hell. But also nontrivial to use some of the patterns that are callback-native in https://caolan.github.io/async/v3/
#
[snarfed]
imo callbacks are a mild antipattern that we tolerated (sometimes even liked, stockholm syndrome style) for way too long
#
[snarfed]
useful occasionally in APIs, but not as a concurrency technique
#
vilhalmer
definitely agree with that
#
vilhalmer
they're fine when all the work is actually happening somewhere else, but when you're writing all the code involved you shouldn't have to call yourself
#
[snarfed]
straight line imperative code is hard enough to read and understand. add in callback hell, and maintenance over time is so so much harder, especially in big codebases
#
[Raphael_Luckom]
I disagree, but sometimes I think my position is more about concurrency in general. I don't want non-library code to show more than one or two asynchronous actions _full stop_. People should not have to understand the implications of async to use tools
#
[Raphael_Luckom]
within libraries, I find callbacks more flexible than promises
#
[snarfed]
google lived through this and learned the hard way, 2002-2012 ish, in both C++ and Java. one big reason that Go (and Go-ish C++ libraries) happened there
#
[Raphael_Luckom]
like this ( https://github.com/RLuckom/raphaelluckom.com/blob/main/terraform/functions/configs/two_way_resolver/config.js ) is an example of "no async outside of libraries" It's a definition of a function that makes a nosql table into an associative API. The flow control is expressed in a DSL without visible async calls. The library implementing the DSL uses callbacks (but it doesn't matter). As you add more complexity to the
#
[Raphael_Luckom]
definition, you don't get any closer to "callback hell" because you're not adding async.
#
[snarfed]
sure! no concurrency (ie async) is one simple ideal. if you’re writing a single threaded tool, and your framework largely prevents concurrency, so much the better
#
[Raphael_Luckom]
well, the framework uses the relationships between things to determine what to do concurrently
#
[Raphael_Luckom]
it has dials for sequential-ness, parallelism, error handling.
#
[snarfed]
sure. i think we’re making orthogonal points. framework constraints like that help. but language primitives (ie _not_ callbacks) do too, maybe more
#
[snarfed]
at least in contexts where _the_ task at hand is concurrency, eg highly concurrent scalable backends. you need tools that let you do that and enable maintenance over time. language primitives like channels and async/await help with that. callbacks hurt.
#
[snarfed]
but agreed, framework constraints help too!
#
[Raphael_Luckom]
With node, there's a boundary between what's in node and what's implemented in C++
#
Loqi
C has 2 karma in this channel over the last year (26 in all channels)
#
[Raphael_Luckom]
fantastic
#
[Raphael_Luckom]
things like async file reads in node are "concurrent" from the perspective of the node runtime, but "threaded" from the perspective of C + + (I think)
#
[Raphael_Luckom]
whatever does the best job of expressing the kind of concurrency you want to use within a layer is the right choice. Sometimes it's promises, sometimes it's callbacks.
gRegorLove, anemoiac, [Rose] and schmudde joined the channel
#
@sonniesedge
↩️ If you're seeing this it also means posting from my site via http://brid.gy is working just fine.
(twitter.com/_/status/1342181899268202500)
[schmarty] joined the channel
#
[Raphael_Luckom]
Anyone have experience using git large file storage? https://docs.github.com/en/free-pro-team@latest/github/managing-large-files/versioning-large-files
[fluffy] joined the channel
#
[fluffy]
I use LFS for game dev projects.
#
[fluffy]
It’s pretty straightforward but there’s a couple of things you have to watch out for.
#
[fluffy]
Like if you forget to lfs track a file type before you check it in there’s going to be some hassle with the history rewrite to fix it, and it’s easy to mess that up.
#
[fluffy]
And of course every git client that accesses the workspace needs to have LFS installed.
#
[fluffy]
*repo rather
#
[Raphael_Luckom]
makes sense.
#
[fluffy]
But yeah if you have large binary files which change contents, LFS is a great idea.
#
[schmarty]
i used Git LFS for storing image uploads etc for my site for a time.
#
vilhalmer
I've been considering that, what made you stop? and what did you replace it with?
#
[fluffy]
If your binaries never change there isn’t any real advantage to it though. The data still needs to be stored somewhere.
geoffo joined the channel
#
[schmarty]
It worked OK but as fluffy pointed out all the places where you interact with git need to know about it and be configured for it.
#
[fluffy]
Like I don’t use LFS for the binaries on beesbuzz.biz
#
[Raphael_Luckom]
I'm looking for a "least bad" way to store some archives used by terraform. terraform has very good support for downloading from git. I want git's commit integrity features but I don't want to cram big files in a repo.
#
[schmarty]
I eventually figured out that what I liked about Git LFS is that everything is content-addressed and de-duped.
#
[fluffy]
My images seldom change and when they do I can do a history rewrite to save a little space.
#
vilhalmer
oh, so you're just committing them normally?
#
[fluffy]
You might also consider git annex. It requires more care and feeding though.
#
[fluffy]
And yeah I just commit my images normally.
#
[schmarty]
I moved all my image and other upload handling to a separate domain using s a standalone micropub media endpoint.
#
vilhalmer
I just like the idea of the image data being in some way connected to the history
#
[Raphael_Luckom]
well, so far I'm not committing them, because I couldn't stomach the cognitive dissonance of using git that way. but when I learned about lfs I decided to take a look
#
[schmarty]
My media endpoint stores everything in a content-addressed way, so I get the deduping that I want.
#
vilhalmer
interesting
#
[schmarty]
And because uploads are associated with my post data, which _is_ stored in Git, I still have a history of all the uploads.
#
[fluffy]
Publ isn’t built to use a separate content store that way and it’s a thing I’ve been considering changing. But I feel like LFS gives you that naturally, if you want to deal with the hassle of setting it up.
#
[Raphael_Luckom]
what I really want is to be able to like "sign" an s3 archive. Ideally I'd want to allow others to use these packages, but I don't want to be the guy that tells people to just pull stuff from s3 and execute it
#
vilhalmer
just committing them directly wouldn't be the worst, since as you point out it's the same amount of bits to move around one way or another
#
[schmarty]
I figured it was a separate hassle either way and I found the media endpoint path a little easier to reason about as a standalone service that integrated with my site.
#
[fluffy]
The only downside I’ve had to checking images into git is that my pack files can get really big and that makes bootstrapping a client a bit more difficult.
#
[schmarty]
[Raphael_Luckom] that sounds like something Git LFS can do for you, with signed commits.
#
vilhalmer
I'm still playing with the idea of exposing the commit history as part of my url structure but haven't determined if it's actually feasible
#
[schmarty]
but with the complexity of Git + Git LFS rather than e.g. an HTTP fetch from S3.
#
[Raphael_Luckom]
right, that's tempting. Im also realizing though that for my purpose, terraform would _be_ the git client (because it pulls directly, so it depends on whether tf supports lfs
#
[schmarty]
fluffy: large and unwieldy repo size is what drove me towards LFS in the first place. another eventual bonus of moving to a standalone media service is that i could tinker with my site in git without having a copy of all of my uploads on the local machine.
#
vilhalmer
good point…
#
[schmarty]
[Raphael_Luckom] it's possible that tf offloads a lot of responsibility to git, which can handle LFS transparently... though i think it requires a kick of some sort after the initial repo clone to be told to use LFS and fetch assets...
#
[fluffy]
Yeah. And also why I kind of want to figure out a way of making a separate image content store for Publ
#
[fluffy]
But it’s a low priority for me
#
[fluffy]
I do like having my entire site contents available locally, and it made image rendition stuff a lot easier to deal with.
#
[fluffy]
But it’s also in keeping with Publ’s “like a static site generator, but dynamic” design :)
#
[Raphael_Luckom]
yeah, it seems more likely that tf offloads git fetch rather than reimplementing it, that's something to check
#
[schmarty]
i've gone the other way and i think of media handling as a separate set of building blocks for a personal site. 😂
#
[schmarty]
receiving uploads and making them available at a URL is a building block, being able to serve different sizes and formats for an image is a building block, etc.
#
[schmarty]
[Raphael_Luckom] i like the way git can be set up to hide a lot of complex stuff under the hood. likewise the way it passes off complexity downstream, like the way it defers to your local SSH config allowing some really fun networking backflips that you set up once and can then forget about.
#
[Raphael_Luckom]
yeah, git is one of my favorite utilities. It's an example of something that doesn't optimize for user proficiency out-of-the-box, but becomes incredibly powerful with familiarity.
#
[Raphael_Luckom]
Another interesting thing that I noticed is that, if you specify a content-md5 header when you store an object in s3, aws will check to make sure its accurate and refuse to store the file if not. So that's a nice kinda-signing flow. https://aws.amazon.com/premiumsupport/knowledge-center/data-integrity-s3/
#
[Raphael_Luckom]
idk...it's sort of exactly what you're not supposed to use md5 for though
#
Zegnat
You should not be using md5 to verify against tempering. But the verify whether an upload succeeded? Sounds like exactly what you want to use md5 and similar checksums for.
#
[Raphael_Luckom]
right...I'm more in the code-signing use case...it's a moot point, aws will use sha256 instead if you ask nicely
#
Zegnat
If that is the integrity you want, you probably want to do actual signing rather than file hashing. Sounds much more like a job for something like https://jedisct1.github.io/minisign/
#
[Raphael_Luckom]
I think adding signature validation to terraform would be overkill...I wonder what kind of verification wordpress plugins use to prove they're legit
#
[schmarty]
[Raphael_Luckom] that question made me giggle nervously IRL 🙈
#
[schmarty]
(in my experience the wordpress ecosystem validates nothing)
#
GWG
[schmarty]: Yup
#
aaronpk
That's not true, it validates the name of the plugin against the ... name of the plugin 😝
#
GWG
The proposal for validation was shelved many times
#
[schmarty]
aaronpk: lolol
#
[Raphael_Luckom]
yeah, I know what you mean. like "it's probably fine" is actually an ok heuristic ~99.9%. And I don't mind accepting risk. But I don't want everyone else in the community to be accepting a 0.1% risk and me out there telling people to accept 10%
#
[schmarty]
was it someone in indieweb chat who told a story about a plugin being straight up hijacked because they had a private plugin that wordpress overwrote when someone randomly published one with the same name?
#
aaronpk
That sounds familiar
#
[schmarty]
gRegorLove maybe?
#
GWG
Yes, I thought it was gRegorLove too
#
gRegorLove
pulls up the issue discussing that which still hasn't had any action taken (cool cool cool)
#
gRegorLove
Happened with plugin named "member-directory"
#
aaronpk
omg that thread is 5 years long and still going
#
GWG
aaronpk: It isnt the worst I've seen
[jeremycherfas], KartikPrabhu and [chrisaldrich] joined the channel
#
[chrisaldrich]
I've run into that naming issue with an official WP repo plugin and a separate github-based plugin before.
kitt and [snarfed] joined the channel
#
[snarfed]
anyone have experience with the chrome extension store’s approval process?
#
[snarfed]
it says “Due to the Host Permission, your extension may require an in-depth review which will delay publishing.”
#
aaronpk
yeah it took me about a week or so to get approved for an extension i made
#
aaronpk
there was no back and forth, it just got approved randomly
#
aaronpk
a coworker got one through that has extremely broad permissions and it was also a trivial process
#
Zegnat
I do not publish in the chrome extension store, but I think there is not a lot you can do? Probably some combination of your account standing in the store + type of extension...
#
[Raphael_Luckom]
I decided to punt on my module storage thing and just use s3: https://raphaelluckom.com/posts/terraform_module_storage.html
#
[Raphael_Luckom]
It can be really hard to look back on a day spent entirely on planning and still feel like it was productive, but there we are.
#
aaronpk
heh i feel that
#
[Raphael_Luckom]
I've learned that the alternative-for-me is even worse--I'll refuse to acknowledge that I need to make a decision about something, and burn a week trying to avoid the decision and get everything I want
#
@ChrisAldrich
↩️ First there’s the details of her post in particular that are cool, but I like how @TheGreenGreek is leveraging Twitter as part of the commenting system on her blog using Webmention & http://Brid.gy. This way for people who aren’t [more...] https://boffosocko.com/2020/12/24/55784090/
(twitter.com/_/status/1342251272649408512)
#
@ChrisAldrich
↩️ First there’s the details of her post in particular that are cool, but I like how @TheGreenGreek is leveraging Twitter as part of the commenting system on her blog using Webmention & http://Brid.gy. This way for people who aren’t [more...] https://boffosocko.com/2020/12/24/55784090/
(twitter.com/_/status/1342251272649408512)
[chrisaldrich] joined the channel