at least I can assume my users know regular expressions

Streamed

Working on Origin model for Lobsters to better handle domains like GitHub/Medium/Dev.to where multiple authors share a domain. Spam patterns and prevention, invite system is critical for Lobsters, vs example of Reddit’s sophisticated spam ecosystem with paid accounts/upvotes/tools. Hard to maintain a good new user experience/onboarding though!

scratch


topics:
  what real bad spam looks like
    an ecosystem of spammers and tools
    spoiler: open signups
  what our self-promo looks like
  big 3 open publishing places that end-run our unseen domain restriction:
    github.com/.io - by far most popular, and least concerning
    medium.com + dev.to - often reposts from unseen domains
  less common
    mastodon/bluesky/twitter
    freecodecamp
  Origin model
    recognize that github.com/foo and github.com/bar are "separate"
      neat to recognize that github.com/foo and foo.github.io are "same"
    mod-written regexp Domain -> Origin
      is it: first named capture is identifier? or named capture
      is identifier just the unique part, or does include site name?
        unique part: 'foo', origin is implicitly scoped to its Domain
        site: 'github.com/foo'
          could this handle github.com vs io? want io return 'github.com/foo'
          nope!
    are controlled by different authors
    tie back to users?
    maybe for v2: handle freecodecamp/others that have author on page instead of in URL
    /domains/github.com:
      needs to explain origins, if this domain has any, what are they
      story/_list_detail.html.erb needs to show Origin for story, not domain
        how does this interact with Origin.identifier? can't assume URL is foo.com/identifier

Origin todo:
x selector, replacement
  Domain: validate .replacement
  safety! test that user can't eval ruby in selector or replacement with "#{foo}"
  editing form
  show on Domain page
  Origin many-to-many to users for better 'is_author' flag? Does Origin do anything at this point?

  new user checks don't work for people who don't immediately start using their acocunts

https://bookshop.org/p/books/the-design-of-everyday-things-don-norman/12398830
https://lobste.rs/s/l64zhd/just_managed_log_into_lobsters_from
https://www.signingsavvy.com/sign/FORGET/3480/1

title: at least I can assume my users know regular expressions

post-stream:
  omg patch out the slow-loading replying_comments cache in dev, too painful
    

Transcripts are generated with whisperx, so they mistranscribe basically every username and technical term. They're OK but not great, advice appreciated.

Recording



03:37his time in the band and a bunch of other stuff. And I would never have imagined they would tour again. And I guess they didn't either, because the tour was called the We Said It Would Never Happen Tour. But in any case, that means I was out late and hollering along with all of my favorite songs. So I may be a little scratchy. I got a big kick out of the fact that everybody in the audience was 45 plus or minus three. I don't know, the concert vibe was just a whole bunch of people who were like, yeah, we thought it would never happen. It was very chill, very friendly, because, you know, 24 years later, band gets back together to do a dozen, 20 shows. Not too bad. So, I wanted to talk about spam and what it looks like on lobsters, which is just kind of mostly relentless self promo and what the big difference is between these two. And spoiler is it's open signups.

04:58So I'm gonna show you another community. There's a community called, microconf connect and it spun off of a not spun off of actually it's so there is an excellent conference called microcon let's show that and go ahead and close that so microconf is a wonderful community it's kind of focused in on sas in the last five or six years it's a wonderful conference run by a guy named rob walling that's him here on the right and jason cohen here on the left is an excellent writer about sass and running businesses but they do offline conferences and they had they're one of those conferences that had a slack channel on the back end you know so you can run into people and meet and this is one of those conferences where the hallway track is like the killer part of the conference they've slowly Reoriented over the last dozen years to focus on it anyways I love micro conf I can't say enough good things about it it's a really warm welcoming community, and if you do bootstrapped entrepreneurship tech entrepreneurship, like the median attendee is. 40 and has a sass and is trying to make their side hustle their full-time job well actually i doubt everybody's a little farther along i'm out of date there has already made and is making you know enough to replace their salary and they've slowly they've tried other things like little local conferences or online conferences but the The back channel for it, the Slack, they made into their own running thing that goes constantly. And the Slack channel always has a discussion running about something, and there are a couple of tiers of memberships. I'm only going to show you something that's in the public Slack. because you could sign up free and you could see this in the public channel. So there's nothing secret that I'm going to show you. I just wanted to give the context of what this is attached to. So somebody asked, come here, let's jump up to the top. Slack has really brought back the old mystery meet, mystery meet, navigation from the 90s where you have to hover over things and so then there's always these controls popping in and out so this person asked yesterday afternoon how do you all go about launching your new products on reddit and other niche slack communities and discord servers because of no self-promotion rules these would be a great place to list them for that but for that And this is kind of a funny question because like the polite version of the question is how do I market my startup in an effective way? But like the implied question is how do I end run these self promo rules so that I can post spam? You might guess this one caught my eye running one of these small kinds of niche communities. And then the, the real surprising thing was somebody showed up and I'm not censoring names here because these spammers can, if these are actually their names, well, congrats, you have, you can have your reputation. So Oliver Fish here says, I do this work quite actively for affiliates and clients. Mainly, the answer is don't make it look like a promotion. We often post a bait thread on one account like, what's your go tool for short editing? Then we'll reply to the top comment on another account and boost the thread with paid upvotes and comment with paid upvotes. So to translate, what he's saying is, well, we spam Reddit. We have one account that pretends to be interested in whatever the topic is that we're selling. And then we have another that appears to be unaffiliated with the company that says, Oh, well, here's a great one, my commercial thing. And then we buy a bunch of upvotes. Reddit does just, you know, they are, they are like a duck in terms of how much anti-spam work they do. And I'm aware that you can see spam on Reddit. But this kind of thing is just enormous. absolutely staggeringly huge and sophisticated. And Oliver goes on to explain, this works well for getting viral traffic, but if you also optimize the Reddit thread for SEO, you can rank these threads in your keywords in about three to four months, as long as they get enough engagement. So here, what he's saying is, is if your comment says something like, oh, what's the best short form editor? Is it foo vid verse bar vid? Well, and then if somebody Googles foo vid verse bar vid, your comment may show up so he's talking about spamming reddit to game google and he says this is all reddit no idea about slacker discords because he doesn't attack those somebody else here chimes in says they've had good luck with passive organic content so this one actually was like hey here's how to market on reddit in a honest and not manipulative not fake way of It is okay to just kind of answer stuff around your comments. And then Oliver came back and he said, yeah, I don't recommend posting links anymore if you can avoid it. The bans have gotten so bad. Well, that's because you're breaking the rule, Oliver. You're a spammer. They keep banning spammers. That's not a, like, gosh, what could have happened here? I generally advise people to post brand terms only, and people will search your terms if you write high-quality content. If you want to post links, you need some testing on a per community basis to see what you can get away with. And again, he's kind of slipping into the like, yeah, obviously I'm breaking the rules. What can you get away with? Links increase your chance of shadow deletes and bans. And most people don't even realize their comments are not visible to anyone. Just assume it wasn't a good channel for them. So this is a spammer saying, yes, the anti-spam tool, it's not obvious when you get caught because you get shadow banned. And that's really inconvenient as a spammer. And then the original question asker thanks him for his detailed answer and says, you know, asks a follow up of what do you use for replying to different comments? And he says, oh, I currently pay about $27.50 for accounts that have been aged and can post in most places. And for upvotes, I use upvote.shop and pay around 10 cents an upvote. arh68 so are Oliver & Vidal the same guy or what LUL
Then of course, 4G proxies. So what he's saying is pretending to be mobile traffic. and all the other anti-fingerprinting stuff you need to do with this scale. I use this undetectable.io to... ARH, you're cutting ahead in line. And he says, I use this undetectable.io to avoid account linking and then just a couple of different mobile proxy providers. So Oliver is really laying out like, oh yeah, so I spam and then here's a couple of dedicated spam tools I use. And... arh68 i wonder who runs those sites Kappa hmmm it's a puzzle
the the scale of the spam is so big that there are commercial services this so upvote shop looks exactly like you'd expect it's just like yeah you could buy packs of upvotes for stuff yeah who runs it so i don't think he runs this undetectable because this one's been around for a few years and it's not Oliver comes off to me as not quite sophisticated enough. Like, he's describing his attack, but he does so in a way that kind of is a little crass and gives away that he's like, yeah, I'm a spammer. This undetectable is technically sophisticated. I believe they have a team behind it, but it is a browser specifically for... You know, I almost want to say spam because that's a primary use case, but... It's also for people who are like scalpers. And I'm not actually super against scalpers. I think a lot of things are mispriced. God, there was that great, was that Kevin Leinag post a couple years ago about charging appropriately for keyboards? But basically it's a dedicated browser that makes it, it's like the souped up version of Firefox container tabs that also attempts to fake other things about browsers so that your different profiles can pretend to be mobile or, yeah. So traffic arbitrage, they mean spam. And then e-commerce is, When they say e-commerce, they mean credit card fraud. And then online betting is if you bet and you win, the gambling sites will ban you. Well, they're not legally allowed to ban you, but they can restrict you. So they'll say, you can't bet $1,000 with us. You can only bet $1. If you lose, you can bet $1,000. But if you win, no. So undetectable, like this is a little savvier about gambling. yeah, we're a crime browser for criminals than Oliver was being about his spam, which is why I think it's not... I don't think that was Oliver that runs this one. He might do this upvote shop thing. The mention of the specific price caught my ear. And so... Vidal, I'm saying it with air quotes, Vidal says, wow, I had no idea of these tools or techniques. I'm blown away by your level of sophistication in this. Thanks for sharing so openly. And then someone asks, do you provide this as a service? And this is around where I joined the conversation of like, well, let's call a spade a spade that there are lots of services that will spam Reddit for you. And Oliver says, you know, happy to share and Oliver and you know, oh, I do spam on behalf of people, but I'm very selective about the clients I take on because some niches are mega easy and profitable and others are nearly impossible. I typically prefer to focus on the easier niches and have a system where I test the moderation on a niche as part of my validation process. That one was kind of funny. Like validation process is startup jargon for if you design a product, Would customers be interested in it? Or actually, let me say it better. A good validation process is less, I have an idea, how do I know if people like it, and more, I see this target market, do I understand their needs? So it's really funny for me to see this kind of business jargon when the business is spam. And he says, oh yeah, there's lots of services like Reply Guy for spam. I don't use them as their accounts are constantly getting banned for spam. which means all your old comments on that account also go down. I believe you're better off writing fewer comments, but mega high quality than spamming AI comments with an automated tool. And so ARH, yes, you skipped ahead ARH. And I said, you're doing your thing here, right? You asked a general question under one account, you pitched your thing under another, and you praised it from a third. And he's like, gosh, I'm not sure I'm following your question. Typically when I do this, I only use two accounts. You don't need to praise yourself if your comments are high quality. People do this organically. So it's what ARH noticed. It's this outline of I'm asking a general question and then following it up with a clever answer from another account that eventually leads into promoting a commercial service. It's very meta that he's not just a spammer. really smells like he is spamming this slack asking for how do I spam slacks that's so I say that this is what really bad spam looks like that's what I put that in my topic because at this point it's it's an entire ecosystem it's

17:59it's a bit like credit card fraud, where like, there are people with specialized roles of we write the content, or we manage the AI tools, or we make the browser, or we make the VPN, or we're the project manager, like Oliver is kind of implied he is, but more likely, Oliver ran upvote shop for selling Reddit upvotes. And Reddit arh68 it's like halfway-dead-internet theory, fake conversations with real ppl
has an enormously hard time of it because of their huge profile and their open signups where anybody can come and create an account and the bad spammers create an account and go to a subreddit and start posting a link to their thing and they get banned in moments because that looks really sketchy the slightly more clever ones they actually have people who know what they're doing working on them and they do really sophisticated things like create per profile well I should say per account profiles where they will use a single IP for each account and they will generate different browser signatures like with that undetectable site or tool and They will do all of that kind of fancy stuff and they will like age accounts for hours, days, weeks, months before they slowly pivot into pitching stuff. And then they will keep the account active the whole time where it'll leave anodyne little comments on unrelated subreddits to build up a history. And then, you know, one comment in a hundred, it'll drop in a link to its thing. That's it's absolutely brutal. arh68 like advanced persistent spam threats lol
So ARH, yeah, you say it's like a halfway-dead internet theory of fake conversations with real people, and I think that's a really good way of putting it, of fake conversations with real people. So Lobster sees a really stripped down version of this. You know, we see the kiddie pool version of this spam problem because we're focused on a fairly small niche. So you can't talk about what's the best pocket knife to buy on Reddit. You can't talk, or on Lobster's, excuse me. You can't talk about... What's the best OnlyFans to subscribe to on Lobsters? All these kinds of things are just not. Yeah, and you say advanced persistent spam threats. I think that's a good way to put it because the spam is an arms race that has been going on for literally decades. And it starts over with new sites. But at this point, there's enough money in spam that some of those commercial folks, like that undetectable browser folks, that they have been in it long enough. So if you start a new site, you are not starting a new arms race. You are showing up to the existing battle and your opponents are seasoned professionals. So that's awful. arh68 I don't even like talking about favorite editors anymore :|
So if you're angry at having to deal with captchas and dumb, your browser looks like a robot, so we blocked you pages, that's why. And it's awful and it's frustrating, but that's why that keeps happening now. Lobster's, boy, our closed invite system saves us from so much hassle. There's some downsides to it, like it is hardest to join the site if you are a new user, someone who would benefit, or a new developer, someone who would benefit most from the site. But at the same time, it means we're not in this endless bot war with professionals. What we do get is What's the right way to put it? Less people who are a little too enthusiastic to promote their thing. And sometimes their thing is they wrote a blog and they really want to show it off. And I go a lot easier on those than I wrote a blog and I want to show it off. And it's the product blog for my product that sells a tool for developers. And wouldn't you all like to give me a bunch of money? So a couple of weeks ago, there was this guy on the site, Dare Gopher. And minutes after he signed up, he started posting links to his various blogs. And that it says story zero because we asked people not to start doing self promo immediately when they joined the site and the about page has a thing about self promo of like hey take it easy, we are a forum, it is nice to have authors here who create stuff, but we are not a traffic source to be optimized, we hope. The.

23:15And we have some restrictions, like if you are a brand new user and you show up with a domain name we haven't seen before, you literally can't post that story. And there's a big red warning that says, hey, it looks like you're trying to do self promo. Please take a minute to slow down and read the site guidelines and join the community and discuss things before you try and send traffic to your site. Derek Gofer did not do any of that. He immediately started posting stuff. So all of his stories were removed because like right after signup, he started posting this stuff and he got a message for each one of these as a moderator removed them. Not me for the first couple, I think it was Church. And each one of them said, like, hey, don't start off with self-promo. Don't do that. And all he did was post more and more and more self-promo. And eventually at the end here, this one, he posted some kind of LLM slop. And then it said at the bottom it wasn't, but it very clearly was LLM slop. Anyway. And then I... I booted him after this because he had had one, two, three, four. I want to say these two were on the same, were both on the last day. Actually, maybe all of this was on the same one day. But it's like, yeah, if you got five warnings, that's okay. At that point, it's just malice. And he had a couple of comments, but they were almost all on his own stuff. So this is a much milder version of of spam this is a much it's also a little fuzzier because he's it's easier to think of him as a person than it is oliver fish like oliver is clearly malicious this guy is sort of like it's a little arguable is he just enthusiastic and really wants to share and the answer is no because he had a product to promote too we'll talk about that in a sec so after a bunch of warnings i banned him When folks get banned, they get an email that says, hey, you've been banned, and here's the epitaph, whatever this banned reason is. arh68 that's a lot of stories for 1 day
And he replied to that email, and he was like, hey, but I don't want to be banned. I want to promote my stuff. And I said, can you tell me something you did on the site that wasn't self-promo? Like, what are you proudest of? arh68 like why does amazon even let ppl publish 3 books a day lmao
Yeah, yeah, that's a lot of stories for one day. This guy is not exactly good vibes like Calvin is, who... Like Calvin is a power user who will post a half a dozen really wonderful topical stories and zero of them will be spam. So this guy dare go for emailed me back and was basically like, well, I think I left a comment on something that wasn't self promotional and the spoiler is he left like a comment on someone else's story. Yeah, I don't know why Amazon lets people publish three books a day. I won't order stuff off at Amazon because you get so many fakes. I mean, what was it? In the first or second stream, we talked about how I can't even buy that one book because Amazon has so many fakes for it. So this guy was kind of annoying. And he kind of... Man, his email was just, please let me back on to spam because I want to spam. And then yesterday he came back. Well, three days ago he came back, and yesterday someone in the Lobster's chat room pointed out, like, hey, wait a minute. These names seem really familiar. This is the same guy. This is the same guy. He even authed his GitHub account. I guess he thought that it was like Reddit where it was so big that nobody would notice or care. You can just keep coming back. The answer is no. If you've been banned, making a new account is ban evasion, which of course is a ban worthy violation of guidelines. frici I love that he even added his mastodon of his old name to that.
frici also hi
He didn't start off posting stories, but literally his first comment, was somebody posted, an article from his blog and he said, thanks for pointing this out. The only reason I reposted on medium is because for Reddit, for some reason banned my domain. arh68 like he's so close to getting it lol
Ah, hey, Freachy. Yeah. Yeah, he... There's a certain shamelessness to admire, like he didn't pretend to be somebody else. But, like, right here, like, Reddit for some reason banned my domain... Yeah, like, gosh, I wonder why someone... I don't... I haven't gone and looked at his Reddit account, because I kind of assume I know what it's going to look like. Because I know what his Lobster's account looked like. For some reason, look at this mystery. Gosh, why were you banned? frici imagine getting banned even from reddit.
Maybe you got one, two, three, four... I can't remember if I banned him before or after I deleted these two. frici What a guy LUL
He wouldn't have gotten the emails if I had banned him first. But it's like, you get five... emails of like stop it with the self promo and then you get banned for self promo and then like it's a mystery as to why sites keep banning you there's a minor thing here that's kind of funny to me where the people's actions on the sites you know their their personalities and their characters And I've had to ban people for being trolls. God, there was one guy just a couple of weeks after I became the admin who was incredibly unpleasant. Like he came on the site to talk down to people just constantly. That was it. Like every day he wanted to talk down to someone. He needed his recommended daily allowance of being a prick. And I banned him pretty quickly after some warnings, And like a year or two later, I was like, whatever happened with that guy? Because like I had had a back and forth where I like I warned him and I tried to talk to him. And like a year later, his Reddit account under the same name was still doing the RDA talk down to someone and be a shit. Like that was his thing. That was his character. And years later, I looked again. in maybe five years later and he was still like that daily every single day I don't know if he even took weekends off he just wanted to insult somebody every day and so I I do send people warnings and try and counsel them because a lot of the times somebody leaves a bad comment and it's just like they got cut off in traffic or their boss fucked them or they had a shitty day for some reason and then they shared it like that's not great but it's understandable like we have all been there and most of the time when someone leaves a rude comment it's just either they're having a very bad day or it's their hot button thing and I only try and ban people when they post something really bad that one's rare or it's just a pattern with them that every time they talk about rust they have to insult somebody or every time they Well, every time they post, they have to post their own blog. So this guy now... I mentioned that these are all kind of... They're a little plainer. They're articles. Some of them, you know, got an upvote or two. But he has pivoted into starting a... I think it's a sub stack. Some kind of paid newsletter for developers. That was the not-so-shocking endgame of this guy was... Where is it? Let's go on the... It'll be like the last thing on the moderation log.

31:37frici substack is what these people tend to flock to yeah
Ah, yeah. Package main tech of... Like, he started some kind of paid newsletter. Yeah, I don't remember if this one... tumdum3 lol, is rust ppl really so bad ? 😞
He's got a custom domain. I don't remember if it's... But this looks like... Yeah, okay. It is a substack. Yeah. So he just wanted to drive people to his paid sub stack. Is rust people really so bad? No, I don't think rust people are bad. I was just kind of reaching for an example and making something up. I don't know that there's actually anyone who's been so deranged pro or anti-rust that they couldn't be normal most of the time. frici it heavily depends, rust has some super vocal and very weird people that help that generalization
No, I was just being silly. There is a lot of heat around Rust, which is why I came to that. But a lot of it is just heckler's veto. I don't know. It's kind of funny. Every time I moderate, I get an email from someone who is like, why did you... You're just intervening because you care about XYZ. And I actually... Like, I code Rails stuff. I have an opinion about Rails. I don't have an opinion about Rust versus C++ and memory safety. Like, it looks neat. frici but rust also has people like Steve Klabnik who are an absolute delight LUL
Some of the type system stuff resonates with me. But I really don't care. And I really don't have any dog in the fight of any kind of community governance. But everybody reaches for, like, you did this because you really want to win the argument. And I'm not. I'm more in the, like, hey, I'm hosting the garden party. We don't have fistfights at garden parties. Please just be chill. It is okay to disagree with people. You just can't call them a douchebag. That's kind of the thing. Yeah, Fritchie says that it heavily depends. Rust has some super vocal and weird people that help that generalization. I think that is every language. That is every tool. It is not really a reflection of the tool. Except in one or two very rare cases. Like, what's the crypto Nazi feudalist guy thing? frici which one HahaSweat
arh68 urbit ?
The guy is Curtis Yarvin, and the system is, he's got that weird database thing where he gets to be king. I forget the name of it now. Urbit. Urbit, yeah, ARH, you got there the same time I did. frici ah right yes
Like that one, anybody who's involved in that one is suspicious because it's literally a software for imposing his political views on computing. Like, at that point, something is fucky. And there's a lot of other weird stuff happening there too. But a general purpose programming language like Rust or C++, all of them have people who get a little too enthusiastic about it. It's fine. All of them have people who who don't know how to behave well in group settings, it's fine. It's not a reflection of the language. And then, Fritchie, you note that Rust has people like Steve Klabnik, who's an absolute delight. Yeah. I think that is a big credit to Rust. Both... Honestly, just him personally. I've followed his stuff since he did a lot of... I think it was just Ruby back in the day, maybe 10 years ago. but I think pretty highly of him. He's written a lot of really good intro stuff. And I think that's enormously valuable to any community is people who want to write intro stuff and get people interested. And I just on stream, maybe what a week, 10 days ago, I showed Steve Klabnick's written a tutorial about jujitsu that, Git, I almost want to say front end, but that version control system that builds on top of Git. And I have a browser tab open off screen to go and work through Klabnik's tutorial. Because I know if he wrote it, it's going to be pretty good.

35:56So anyways, this is kind of what Lobster self-promo looks like. You know, we do get like real spammy stuff sometimes, but this one, it's just kind of somebody who's way too enthusiastic about their thing. frici its kind of both apparently its git compatible but it also has its own backend to be potentially just its own system "someday"
And in this guy's case, he didn't want to do anything except promote his sites. frici I have the same tab open still since your stream LUL
And he kind of pretended on his fan evasion and he left a couple of comments on other stories. They're all really thin. Yeah, Fritchie, that's why I struggled to summarize it, is because it has a Git-compatible backend and then also might be its own thing. And then Klabnik linked to that introduction post by, I think it was a Chris somebody. And the blog was named either Sym Mathesy or Sym Poly Mathesy, something like that. There are two blogs that have the same latiny title that i couldn't remember anyways yeah i i think jujitsu is neat i have just been so busy running around the last week or two that i haven't gotten to dig into it i'm i'm trying to figure out like where can i dedicate two hours and just block it off on my calendar so i can just play with it and do some lobsters coding with it i don't quite want to want to struggle through it on stream frici https://v5.chriskrycho.com/essa… the post pushcx is talking about
So I wanted to go back to the stuff that this guy submitted. So there is an interesting thing here. frici and steve's follow up https://steveklabnik.github.io/…
So I mentioned that we have a restriction on new users that they can't submit stuff from new domain names. But he didn't. We have freecodecamp.org, again, medium. Oh, Fritchie, thank you for finding those two links. I appreciate it. And then he has Medium, and then GitHub, and then YouTube, and then this is just a text post. arh68 SeemsGood thx @Frici
And this one, I don't know if he, yeah, there's another thing with text posts, but he was kind of end running that domain restriction by posting on these sites where anyone can sign up and post to them so like medium github and dev2 are the three big ones we see from folks who want to show up and do self promo right out of the bat and by github i mean both github.com and github.io this free code camp there's one or two smaller ones but those those three of medium github and dev 2 are the big ones and of the three i don't know it's funny because there's so i'm gonna write this down

39:32The interesting thing is these are by far most popular and least concerning. And I say least concerning on GitHub. I'm going to say or .io. They're people sharing code projects, and they've only rarely been, you know, this is a commercial project. This is a open core project. This is a read me for our client library for our SaaS. That kind of thing is real uncommon. What it is instead is someone who is, hey, I made a neat thing and I want to show it off. So I have to be the no fun police because we have to have a legible rule of don't start out with self promo. but I'm a lot less worried about it when someone is like, here is a neat, well, Rust library I made, or here is a neat programming language, or a toy compiler, like that kind of thing. Somebody's going to do one or maybe two of those, but they're very low abuse, you know? It's very minor. It's like, okay, it's a little rude to take before giving, to... drive attention to your thing before you are really participating in the community. But it's not bothersome in the way this I'm starting a newsletter and I want to get signups is. And Medium and Dev2, I kind of lump them together in my head because they're often reposts from unseen domains. So on these, you can repost your company blog here to these two sites and people will to end run our restriction on domain names. Or maybe they already post their company blog to those because they want the distribution of being on those sites. And when they see the error message, they back out and they post the Medium or the Dev2 version of that. I should mention in here that Let's make sure I'm in the right directory here.

42:03There's a thing that people don't notice, which is the validation that if you are not submitting an unseen domain from a new user, it tattles on you. So there is this model in the database called ModNote that is a note for moderators. They are either by moderators or by the system itself. And they log when people do things like, I tried to break the rules. So this message down here of, you have to prepend the domain name. So, you know, example.com is an unseen domain from a new user. We restrict this to discourage self-promotion, give you time to learn about topicality. Oh yeah, new stuff is very often off topic. Skirting this with the URL shortener or tweet or something will probably earn a ban. This is a weirdly draconian and strict message. It's gotten stricter over the years because I want to be really unambiguous to people of like, we see what you tried to do. If you break the rule, we will boot you because at that point when people deliberately break that rule, it's evidence of bad intent. That's a like, I see what the error is. I see what the rule is. I am going to go break that rule. Like, yeah, yeah, you can break the rule, but if you break the rule, then we know you don't give a shit about rules and there are going to be other rules you break. And so having a, an unambiguous one that people can run into and can try to end run early on is just kind of useful for seeing those people and dealing with them and you know a lot of the time dealing with them is i send them a sharply worded private message but it's much nicer to do that on somebody's second day on the site rather than like fifth week where this is a pattern and we're discussing it and it just becomes a giant time suck if someone is deliberately breaking a rule that says you're about to get banned it's not so surprising so this tattle it just logs it Where's mod note? So there's not really, it's in the code, but I don't know that it gets called out on the site. But if someone tries to log in while banned or do other stuff, it's just called tattle because it reports to me. I think this one about redeeming invites was the first one where occasionally people will try to redeem invites when they're already logged into an account. like 80 of the time that's they forgot they had an account and when they clicked the link to open it or their friend proactively tried to invite their friend which is wonderful but they the friend already had an account and so when they clicked it they tried to redeem one while already logged in but then that like one time in five actually much less maybe one time in 20 it's someone who wants to have multiple accounts so they can upvote their own stuff and they weren't They weren't using that nice commercial service that Oliver Fish helpfully explained for spam. So I have a couple of these to tell moderators that interesting things are happening on the site. The older I get, the more into logging I get. This kind of logging is just absolutely invaluable. Previously, this was me grepping this stuff out of the production logs. Not scalable. Doesn't work with the other moderators. so yeah i mentioned the where's the new domain oh tatalon story domain it's a a generic one of hey if you tried to post for a unseen domain as a new user or a banned one this is the message that goes in the log So anyways, that's kind of that excitement, but the hassle here is that domain is not a good, it's a reasonably good proxy for a site, but it is not a great proxy for authorship where, you know, every github.com slash whoever is effectively another site. And everymedium.com slash whoever is another site. And we're not really doing a great job of catching early self promo with specifically these three sites. arh68 what happened to geocities, angelfire.. dreamwidth
There are a handful of others like FreeCodeCamp that show up often or less often, but it's these three like almost always. What happened to GeoCities, AngelFire, DreamWidth? Yeah, what happened to LiveJournal? albynton Hello!
zoom.com X O M. I want to say that was my first personal site. arh68 hello Albynton
God, a million years ago. What was that? 94, 95. Oh, Hey, Alvin 10. Welcome back. The, there is a lot less of that stuff. Now. The other thing there is, is, there's well, there used to be Twitter. Now there is X. People don't submit links from there very often. Those are kind of often bad because they're so thin and that sites, even before the change in ownership two years ago, year and a half ago, whatever it was, even before that, it really incentivized hyperbole, just to reuse the word from the last stream, right? arh68 reading stuff over there is so .. bleh, like raking leaves, just the ui
It incentivized arh68 all the replies are scattered
making everything into a fight and making it this guy is doing something immoral in secret to you yeah reading stuff over there is blad like raking leaves just the ui i'm not sure i follow the phrase like raking leaves just really tedious work where like the leaf slips out from under the rake and you have to do it again and again and again is that where you're going all the replies are scattered yeah arh68 you just kinda pick thru a handful, then another
yeah i it's funny since the the death of twitter i've moved over to blue sky and mastodon and it's like all the developers went to mastodon and all the everybody else went to blue sky and i kind of wish the developers had gone to blue sky it was it was less mature than mastodon at the time but spartangtr which mastodon instance though
spartangtr twitter is a ghost town for tech now
On Blue Sky, I really like that I can do the, I would say, quote tweet, but it's repost with message because I like to see people talk about stuff and yes and it in the improv sense of let me build on your thing, let me share stuff. Which Mastodon instance though? I moved over to... octodon.social, and that one is winding down. And so I've moved over to ruby.social, which is a really friendly tech-heavy instance. Even if you don't do Ruby, I think it's a really promising choice for developers because it's just a whole bunch of devs hanging out. I read the local timeline a lot more than I did on Octodon. But I can't, on Mastodon, I can't do the yes and quote post. Mastodon has decided that that is more often used for dunking than contributing, and I understand how they came to that choice but at the same time it really frustrates me because i see lots of nerdy stuff and i want to be like yes and this is like i don't know that other compiler yes and this is like the difference between property testing and unit testing and i can't i can't yes and on mastodon

50:34freekex Every twitch programmer I watch has a Twitter account including the really popular ones like ThePrimeagen
Every Twitch programmer you watch has a Twitter account, including the really popular ones like the Primogen. freekex Hello
Hi, Freekacks, welcome. Yeah, when I started streaming, I went and read a whole bunch. I know someone offline. I guess I know her online, too. I know someone who's a Twitch partner, and she streams video game stuff. And frici I think mastodon is trying to focus people to contribute that in replies to OP although there is the problem being ... getting all replies in a thread is nightmare, absolute nightmare NotLikeThis
was like yeah one of the things you have to do if you want to build an audience is you have to make clips where you have funny or interesting moments and then you have to post those clips to utah youtube and tick tock and twitter because that is discovery for your stream and i i'm too old i kind of loathe short form vertical video i'm just allergic to it in the way like bluwumeaway despite custom feeds, i wish bluesky had a local feed for people on the same pds. mastodon has a great sense of community and bluesky is very global
One's grandparent refused to use a personal computer perhaps. albynton You probably know this already, the mastodon developers said they are seriously working on "quote-toot" for the next update
so, and I'm doing this streaming because it's a lot of fun to code on stream and to talk about what's happening in lobsters and answer questions. But it's not a, like, I am going to become a Twitch partner with my rails programming and become a millionaire. Like that's, that is not at all a thing that is happening here. Ah, welcome. Oh man, blue womb away? I'm so bad at pronouncing these nicks first time off.

52:04freekex Oh yeah I was just responding to Twitter being a ghost town - I haven't seen that
Yeah, Fritchie, it's funny that you think, no, bad phrasing. I see where you're going with Mastodon probably wanting to incentivize direct replies, but Mastodon doesn't surface replies. You don't see them unless you either click into the thread or if you follow both people. freekex I read Hacker News headlines multiple times daily and I still see links to Twitter way more than Mastodon, BS or Threads
And it's funny because Blue Sky, they've tweaked it a lot in the last year or two, but you can see replies from people you follow to people you don't because they wanted that for discovery. It's had some complicated social effects, and they've tried to tune it to minimize dogpiling and other nonsense. frici Oh sometimes you don't see them even if you follow both people or if you open both servers (if in different servers) XD
And there's that whole concept, or whole problem of concept collapse, or what is it? Context collapse. There we go. So it's funny that Mastodon doesn't have that. I was totally unaware that Mastodon developers are seriously working on Quotute. I think that is wonderful. I really hope that does come in soon. It is my one pet peeve missing feature from Mastodon. And I will probably get a lot more active on Mastodon if and when I can do that. Blue, you say you're looking for a local feed for people on the same PDs. What is a PD in this context? And yeah, I agree with you that Mastodon can have a great sense of community where Blue Sky is much bigger. frici I so deeply want mastodon to work but oh boy... sometimes Activity pub makes me dizzy by its decisions
Yeah, I don't know. It's funny. I know a couple of people in entrepreneurship who are still hanging out on Twitter. Neither, excuse me, the, both the funded and the bootstrapped entrepreneur folks. And I guess I'm alighting the word tech. bluwumeaway a PDS it is the backing datastore that stores the merkle trees repos for user accounts
Cause for me, it's just assumed are still on Twitter, but I expect them to all kind of move over to mastodon or I'm sorry, over to blue sky in the next couple of months because of the many changes that we don't need to rehash happening to X. Yeah. all right so i am gonna mute for about 10 seconds so i can clear my my old man went to a concert on a weekday through okay a pds is the backing data store that stores the merkle tree repos for user accounts oh is it personal data server yeah i know the ad protocol has some distributed stuff i've looked at it a little pushcx https://github.com/lobsters/lob…
I was curious about, we have a open issue on lobsters where I am hoping someone wants to contribute this, but if you would like, if anyone, especially if you know something about the app proto, we have integrations with GitHub accounts and Mastodon accounts. We used to have Twitter. I think Keybase is still in there, but that product is kind of dead and I should probably remove that at some point. It would be nice to have Blue Sky and App Proto at the same level that we have Mastodon. I looked a little at the API and the other stuff and they are very They're a very JavaScript-oriented ecosystem, and a lot of that is youth. It is a new protocol. It is under very heavy development, and so it makes sense that it's kind of a monoculture and that the docs are a little bit thin. But I didn't want to put any kind of node service into production. I just don't have enough experience to have confidence in it. bluwumeaway i think they just pushed an oauth workflow
And so maybe, I don't even think there's a at proto gem for Ruby yet. Is there? If there is, this would be a lot more straightforward. I did this last time. Or is it Ruby dash? Yeah, Ruby dash toolbox. You think they just pushed an OAuth workflow? freekex GitHub is literally the only social network I contribute to outside of Twitch and I just deleted my 14 year old GitHub account to start a new completely anonymous one
frici they actually just have yes
Well, if they did, we... Where is it? freekex I feel so free!
I thought we had... Well, that's actually really wonderful news. So if you look at our Mastodon or our GitHub integration, they're really... This one's more complicated, but there's less happening in the GitHub one. If you look at our... github oauth flow it's not a lot of code here what is this 46 lines it says so if they have an oauth login and you would like to add support for that i would love it so i mentioned this open issue for supporting blue sky i don't bluwumeaway as far as ruby gems go there is https://github.com/shreyanjain9… but i dont know how up to date it is
If you want to work on that incrementally of just do the OAuth so people can link their accounts and we will come back and add the other stuff later, even just a partial implementation would be really appreciated. I would really appreciate it. Oh, I lost my Ruby toolbox tab. Yeah. so blue says that there is b sky rb that's is that farther down here okay so it's missing from the ruby toolbox here which has i kind of poked around at these gems and they all looked very new and kind of immature like I don't mean to insult any of them. They were toy projects. I don't think that's an insult. I hope someone doesn't take it that way because I think there is a lot of room for experimentation and tinkering and playing in programming and that is a wonderful way to get the hang of something or just explore and practice. I didn't look at the, yeah, skyfall was for going to the fire hose, which if I wanted to build a blue sky bot of some kind, maybe. So what is bskyrb? It looks like it's maybe defunct if it hasn't been touched in 10 months. Yeah, last year is the last commit. And in a quick-moving protocol like the app protocol seems to be, I would be kind of surprised if this gem worked. frici 10 months ago ATP was extremely different from today yeah
Yeah. Anyways, it would be nice to add these integrations. frici they made big jumps in the last few months
We occasionally get people who are like, what if we rebuilt the whole site so it all worked on activity protocol? And... I appreciate the enthusiasm, but I don't want to take something that fundamentally works and then rebuild it on a experimental platform where almost nothing works that way. There are options like that. There's a bluwumeaway lemmy or kbin are kinda like that
what is that called starts with a p there is some forum that runs on top of the activity pub protocol i can't remember the name of it offhand and yeah fritchie okay so if you if you're a little bit familiar with the app protocol i appreciate you sharing that because i sure don't know what the current state of it is but if there's If there's OAuth, look at our GitHub integration. Lemmy is the one I was thinking of. Thank you, Blue. I don't know why I thought it started with a P. Maybe I'm crossing over in my head with Pleroma, which is sort of an alternative interface, but Lemmy is the one I was thinking of. And if you want that, it's out there. I think that's neat. So yeah. Come whitewash my fence. This is available. What is it? This very first thing. You could PR that. You could PR that today in the next hour or so. I'll review it on stream. So jumping back from all of the fun distributed stuff, we ran into the limitation of the domain model that A lot of these sites or a lot of these popular things don't really match up, and so I had this idea of having a origin model where. It would be something that understood that a domain like github.com or github.io isn't a singular site it's it's many things with many authors. and Another limitation of the... Let's jump back here. Oh, I'm not on the right branch. Yeah, that's... So I've been working on a gem. It'll be available for other languages, but working on a gem called Recheck for database integrity, and I tested against... lobsters because lobsters is a real production database and anytime you've got a couple million records you have a couple squirrely things in there yeah that's just kind of a placeholder there model story i wanted to go back to the story model one of the hassles here also is this if user is new is very limited and it's a little orthogonal to the hassle we're having but a thing that happens and it's not malicious like i was describing with reddit i said on reddit folks will well the spammers will sign up and they will age their accounts for weeks or months before they start posting spam what happens on lobsters is people will get invited and they will sign up and then they will not really get hooked on the site you know they will maybe leave one comment or one vote and then forget about it for weeks or months or even years and then come back and be like oh yeah i remember that site i had an account let me be active there but then none of the new user checks follow fire even though they are new to the site effectively so there's a second thing is like new user checks don't account for people who don't immediately start using their accounts.

01:04:13So I just want to write that down. I don't know that I want to like take that part of it on, but there's something about. Hey, have you been active on the site in the last, say, six months? then regardless of whether your registration is brand new or not that might be a good time to kind of work into a not heavy restrictions but a more supportive workflow so like if you look at the story form where was it view store form i'm getting tripped up by rails's rails is pluralization again but if you look at this the story guidelines whoa easy cat easy buddy cat's on the desk and i i bumped the mouse and then he got bumped by the mouse and then a fence so this the story submission guidelines that we worked on on the last stream and the stream beforehand trying to improve this text This question of whether to show the guidelines for the user. Where's that one defined?

01:05:33Stories helper. I could have guessed that. If you've submitted fewer than five stories or you have had a story removed or edited by a moderator in the last Really only last five days I thought that was longer than it will the story guidelines will be open so they're a little more visible so that's the kind of. Less slightly more sophisticated hint that I would like in place of a lot of is new checks. And this could be better of instead of if stores submitted as less than five how about. stories submitted in the last six months is less than a couple two or three well then let's show you the guidelines so you can see them again and the guidelines change rarely you know call it once a year on average maybe once every two years on average but i don't know i really like those kinds of well let's let's just kind of keep nudging things let's keep hinting things let's try and have Instructions at the point of use is the big one. There's a wonderful book.

01:06:57If you haven't seen it, this is... There we go. Very SPA site. A wonderful book by Don Norman called The Design of Everyday Things that has this... very impractical teapot on it and it has i don't think there's much that's specific about computer user interfaces but this is one of the best books on interface design in part because his examples are things like when you walk up to an unfamiliar building Can you immediately recognize whether the door is a push or a pull? And isn't it frustrating and don't you feel kind of dumb when you guess wrong? And that's super frustrating. And Norman's point is, hey, that's not you. You're not dumb. You didn't make a mistake. Whoever designed that door failed to make a door that was immediately intuitive. Doors should not be hard. We all use, you know, a dozen doors a day. It should be trivial to look at it and know what you're supposed to do. Not just because, like, it's just a door, but also if you are going into a business for the first time, like I'm going into the china shop to buy something nice. the first thing i do should not be to feel dumb and slightly ashamed and publicly embarrassed that i up the door like that's that is not the experience that's not the mood that a shop wants you to walk into the building with you shouldn't walk into your doctor's office feeling useless so i really i cannot strongly enough recommend this not just if you do interface design But also it's one of those books that will change the way you see the entire world. You walk around with a very different set of eyes. But that book is where I picked up the idea of we really want to put instructions at the point of use. That is the big value of stuff like the story guidelines, trying to pop them up when people are less likely to be familiar with them or pop up the restriction on unseen domains. It's right when we know someone is curious about something, can we put the information that's in front of them at the exact right time for them to learn it or make best use of it or avoid a mistake? That kind of thing is just really friendly and thoughtful.

01:09:49So let's add an origin model that understands that GitHub and Medium are... like a hundred sites or a thousand sites or a million sites in a trench coat rather than one.

01:10:18Now we can see how badly I can memorize Rails migration stuff. I need the T.

...40So really what I'm getting at is I want to be able to say that are separate, you know, and it's sort of getting at this idea of authorship. like they have they are controlled by and so for a field let's have the timestamps i'm happy to have the default timestamps and what i want is so i'm going to keep the domain model but i want to have some kind of like regex to go from domain, let's use caps so we know I'm talking about the model, from domain to origin. So what's going to let me recognize that these things are different? And it would be neat to recognize that github.com slash foo and foo.github.io are same. That would be one origin.

01:12:24arh68 so what about like official github paths, though
arh68 is there a good way to detect like github / status
So what about like official GitHub paths though? I'm not sure what you're referring to. Oh, like github.com slash readme or github.com slash status. So yeah, there's their blog thing. Oh man. So as a upfront warning here, I'm just not going to click on it. GitHub has some kind of, bug in the css for this where occasionally when i click on these individual stories they have a heavy strobing effect i've reported it a couple of times but like the entire page or the entire header that spans the page flickers at 60 hertz it's incredibly off-putting i don't know what that bug is i've tried a couple of times to to report it to them, but I haven't gotten any acknowledgement, so I think that is more, it's really hard to tell big companies about problems than they don't care about triggering epilepsy. Anyways, that's a little bit of a side topic. I think... If we did this github.com slash foo, it would recognize status and read me as two separate origins, and I am okay with that. Or github.com slash help, or docs.github.com. Well, that's already going to be a separate domain. Because the way we're going to use this origin is to... nudge or restrict new users and i want that to trigger even for stuff like github status pages because a uncommon thing but on lobsters we basically don't do popular service x is down stories they don't The notification that GitHub or Anthropic or any of these other sites that are common with developers is down, it doesn't generate any interesting comments or any interesting discussion. It's just sort of like, yep, it's down. Well, there goes my day. I guess I'll do something else. I'll surf Reddit. And we just rehash them. The postmortems for outages tend to be kind of interesting. So we do take those. But the temporal like so-and-so is down right now, it's just we don't get a conversation out of it. So we don't take that. And so it's actually kind of good that that would fire for github.com slash status because then new users who don't know that we don't do that will get caught up. So really... If we're going to have these regex, I would really like to have them on the origin model, but I don't want to have to scan them every time. So I think origin, as long as origin points to domain, when a story is submitted, the domain can look up and run all the regexes for any origin that points to it. So I think it's fine to have the... String here, so say T string. What do we call it? It's like it is a regex, but I hate naming things by type. It sort of is the qualifier or is the selector. Something like that. Selector seems reasonable. And then do I have to touch domain at all? I don't think so, because this will point in. I think that's good enough for now. So let's add that. Gee, why am I recording a macro? Thanks, Finn. And now let's go add the model.

01:16:54Wow.

01:17:03So I'm going to have org and domain up at the same time here. I don't remember the default for optional. I think it defaults to be true. So we'll just say that it validates. The domain is present. And the selector is present. And we're going to have to validate the length of the selector. Now, really what I want to do is just grab this and customize it.

...57That's fine. Why are you giving me Remove explicit president. All right, so I guess standard RBS complaining that I suppose it is implicit for the remote key.

01:18:20I'm going to end up, I guess, making admin UI for this or moderator UI and having to log things about it. So we'll say that this has many origins. And those can be optional, so that's fine. GitHub or Vim. I think Vim is getting a little annoyed. So I have a... standard run and lint the file and autofix in the background and occasionally vim like i think does it in a background thread and gives me that like oh somebody else edited the file when it was really just standard rb operating in the background it's some kind of timing issue because it only happens one time in a million so let's add a controller do i have a i don't have a directory for it I'm kind of riffing on the domain controller.

01:19:57My... My goal here is to make it so that moderators can update domains. Maybe this just wants to be something on the domain form, right?

01:20:34I guess I'm kind of equivocating between, is the origin that mapping, like the regular expression, or is that the individual site, like there would be one record for github.com slash bar? Yeah, the regular expression has to move up to domain. It's in the wrong place.

01:21:09Help if I could spell.

...16So if I'm going to do this, I'm going to go add column to domains. And then this one gets a string named selector. And it can be null. And then this gets a So it needs something to store that slash bar or identifier, I guess. There we go. So we'll validate the identifier. And I kind of, well, let's put it in a list.

01:22:11A thing that comes up often and is part of the impetus for this origin model is we don't have a concept of owning a site. But sometimes, like if you see push.cx, well, that's my blog. And we can associate that one-to-one with a user or even just n equals one many-to-many with me. And that sort of thing, it would be an upgrade to the, like, user is author checkbox on stories where people indicate that they are the author i would like to kind of improve that without taking on the huge feature of who is considered an author or having to authenticate domains you know like make this dns record to prove you own a domain i don't want to get into that, I think it can be run on the honor system or on the moderator judgment system without being too much work. So let's look at this guy. So it has many origins and then it's going to validate the selector. And we'll give it a length. But it doesn't have to be present. All right, let's fix that.

01:23:55So then what I'm thinking is that the domain has a selector. And if it has one, when you create a story, we can look at the selector. and figure out if this is an origin, and then create the origin record in an idempotent fashion, find or create by, and then, oh, thanks for asking. Yeah. So that looks fine. Let's run that migration again because I tweaked things. Can't drop column string. Oh, so. All right. Is it DB rollback? I swear, Rails changed this like five years ago and I can never remember. Oh boy. All right. I can do this. I will manually roll back. So what it's mad about is I tweaked the migration to add that column, and so it can't roll back because that column doesn't exist.

01:25:37And yeah, I'm going to make sure it knows that we haven't really run this migration schema migrations. All right. Now I can run it again.

01:26:07And you are mad about me calling it selector because I swapped the order of these arguments.

...32The fun one is going to be figuring out how to nicely serialize a regular expression to the database and validate it. So I'm going to work through the steps here from the admin perspective. I guess I don't really need the browser open for a minute.

01:27:01probably going to come back to that migration and add some or no i'm gonna have to make a second migration just to add some default origins or i'll do it manually in prod i don't know we'll think about that but stuff like github medium dev 2 x yeah the free free code camp is a tricky one here because we do see that one often enough but Let me grab from the other browser. So if I bring up... So this is one of the self-promoters' articles. And a little annoyingly, they don't put the username in the URL like you would expect. They have it on the page. But that's... it's a whole second step of well, then we have to retrieve this page and parse it. And so I don't quite want to get into that it feels like a nice thing for v2 of origin. But for now.

01:28:30Yeah. to phrase it in a positive way, that have the author on page instead of in the URL.

...44So coming back to the domain, we have this selector. Yeah, that'll have to get more sophisticated, but it's fine for now. Let's go up to the controller.

01:29:02And I'm actually going to turn this down. I think it's okay for moderators to edit domains like this, both for bans and for editing origins. There is a limitation that only the administrator can ban users. And I feel like banning a domain is just much lower stakes it's not a personal you need to go away in the way that a band user is so i'm gonna relax that and where's the params we don't have a domain params yeah okay we do So we'll permit selector as a field and then go up to the domain form. What's in the views? That's called edit. Bless them, the templates are not super consistently named, and I just have to memorize them for the various models. I've been slowly shifting stuff over to more closely mirror the Rails convention, but that's a decade project because I don't like churn for churn's sake.

01:30:41So we're going to have another field called selector.

...56Let's get this up on screen so I can see what it's going to look like. I always have to think about that. So we go to local. Helps if I start the Rails server, right?

01:31:20Oh, I'm even logged in. Oh, github.com is right up top. How perfect. So let's edit this one. So this is the moderator form for editing a domain. And it just has the one field for banning. And I want to add more.

...54It's not required. I'm going to make this a second form. I don't like the idea of changing this to edit. And then if you fill something in, the site is banned. And if you remove it, no. We're going to make a second form. And by second form, I mean I'm going to rename edit.

01:32:32But how will you get there? Yeah, we'll just make it a second form on the same page. This already has an if of, well, if it's banned, you'll see it, and then you get a form for unbanning, right? No, you get the same form. I'm okay if they're the same on the back end, but I don't want the... I just really don't like having BAM controls so close to something anodyne.

01:33:17So here we'll have the selector.

...37It needs more vertical spacing, but that's kind of a rough draft. I am especially okay with moderator admin interfaces looking a little bit clunky.

01:34:01Do I have a... There's some CSS styling for making that wider. Oh boy. I'm especially tiny here. So we have the story title, we have a max length and then is it just CSS selector on it? Yeah. That makes it wide. Okay.

...43so does this already have a unique id on it i don't think so one of these days it's in the issue tracker if anybody is feeling especially spry and designery we really should rebuild all the forms and the basic page layout to use css grid it is we predate css grid which is why we're not using it but there are a lot of There are a lot of brittle things or clunky things because we don't use grid. We use float and widths and other stuff. So I'm going to say...

01:35:45arh68 is there like a minimum browser as far as can-i-use ?
kind of following this convention is there a minimum browser as far as can i use no not really i think everyone for all browsers for the last five years have supported css grid you know accepting things like links or a screen reader and i like the site to continue working in those I don't have a specific thing I just try and be fairly conservative because we get people running. Very unusual browsers like dillo and net positive I don't remember if that was an alternate name and there was. There was somebody else. Some novel browser that used lobsters and correctly rendering our homepage as a. like milestone for their browser development. gmem_ Was it servo?
albynton ladybug?
So I try to be kind of conservative about our CSS and other features, because developers have a lot of fun setup stuff. But Ladybug, maybe that was it. I don't know why my local one isn't loading, but we'll go here.

01:37:20frici notsure about netpositive. maybe you were thinking of webpositive? Web+ is what haiku ships and i know a few haiku people are browsing lobsters
No, this isn't it. Not sure about net positive. Maybe I was thinking of web positive. Yeah, net positive is the name of the browser from BOS, which I ran 25 years ago on the desktop.

...50frici that's why i wasn't thinking about it LUL web+ is the spiritual successor yeah
web positive is one of the more uncommon browsers we see was there a milestone no i don't remember it someone it was a a top story because everything meta goes to the top but there was some independent browser that used our homepage as a target for do we support html and css well enough to be usable not you know the total ship it live it's perfect but hey well this is a nice intermediate goal because our page you know it has one or two quarter cases but it doesn't do anything too wild and it's a nice real world thing and fritchie yeah you're you're definitely remembering browser history better than i am for this kind of Was it Lobster's homepage?

01:38:54Lipsurf. No.

01:39:06Yeah, I'm not finding it. arh68 what about "Just managed to log into Lobsters from SerenityOS "
There was someone. I'll have to dig back at some point. So I just want that to be wide. So we'll say div domain box. Wouldn't mind if the band reason was wider too. And we didn't grab it. Didn't save the ID on the form. What about just managed to log into lobsters from Serenity OS? Yes. ARH, that's it. Serenity OS is the one I'm thinking of.

...59Oh. and it's what Albenton was thinking of. It's not Ladybug, it's Ladybird. That's the name. One of these...

01:40:25pushcx https://lobste.rs/s/l64zhd/just…
There it is. Here's the story. Yeah, 144 points, that leapt up. I think the, what do you call it? I don't believe it was just an individual who used Serenity OS. This is not going to load, right? Yeah. Oh my God. No, no. We're entering a new phase where our browser is capable enough to participate. yeah and it's like okay the the layout is a little funny, but it it's basically all there, I was really happy for them and it's really fun to see the site use that way as a milestone let's paste that over here in the. scratch. Thank you for helping me remember. case you're wondering anyone like yes so like on stream today like three or four times i have been like what was the name of that thing the guy from the place that one time so i really appreciate having the chat around to be like you're thinking of x but when i don't have the chat or my spouse around to do that i do just kind of wander around in a haze of half-remembered things there's there's actually kind of a joke about that in so i have a friend who as a kid was told that he was going to go deaf as he grew up and so his parents taught him sign language as he grew up and very luckily he did not end up going deaf but it meant that as a kid i learned a little bit of sign language to talk with him and when we were in high school together we would if we were separated in class or told to not talk in class, we would just sign to each other in class, which is one of those, like, you know, the program, the teacher tells you don't talk in class. arh68 whoa mister end-run-around-the-rules
So when you start signing, like, well, we're not talking. Yeah. Okay. Thank you. Thank you. Teenagers for being very literal about following the rules. Yeah. frici Andreas Kling has moved away from serenityOS so its unlikely lobste.rs will remain a milestone for them as they will start including more generalized code and deps than only DIY/NIH stuff. But it was def cool to see.
Well, Mr. And around the rules, you know, if they, if they thought anyways, I, Yeah, that's a good call. There is an irony here that I am pointing out that people end run our rules and that I am talking about. albynton You were not speaking, but you were talking
In my defense, I was a teenager.

01:42:59Oh, Fruity with more interesting context that. Andreas Kling has moved away from Serenity OS, so it's unlikely lobsters will remain a milestone for them as they'll start including more generalized code and dependencies than only DIY NIH. Yeah, I had no idea. I have been delighted by the way people reuse the site and as a various or the code base and come up with these things. So what I was going to look for was, is it

01:43:37So I had a roommate for a while who was deaf, and I've known a couple other people who are hard of hearing or deaf, so I actually know American Sign Language pretty well. And so this is the sign for forget. You kind of wipe your brow like this. And so American Sign Language is one of those cultures where you don't give yourself a name. Other people give you a name. And it is a kind of a very deep community norm. If you show up with a name sign that you made for yourself, people will be like, oh, oh, you're a hearing person. Oh, you don't actually know deaf people. It's pretty universal. And so the sign for my name that I was given is the sign for forget, but instead of starting out with this flat open hand, like a B, because it's, well, with the thumb out, it's almost a B hand. They do it with the initial P for Peter, and then they just do this gesture of forget, because I have just... I don't know. It's like somebody buckshot it, but I have just a spotty memory. That's why I built things like the mod node is I can't remember all of this stuff perfectly all the time. And that's why I'm always like, what was the name of that thing? The other one I do with friends is like, I'll tell someone a story. And they're like, yeah, I've heard that story like four times. I was there for that story. That is a story about me. That's how I got this peg leg. Why are you telling me the story of how I got a peg leg? So that is why my ASL name sign includes the word forget. I'm kind of forgetful. That's OK. Get it done. It's funny, though. I do have an excellent memory for code. I had a friend who went to a programming boot camp in Chicago 15 years ago, 13, something like that. And I met somebody else who was in their class at, like a mixer we're gonna grab that link and i forget her name we'll call her alice just for a generic name and you know i'm a couple of months later i i saw they had a whole thing where if you did your homework you could see the solutions that other people submitted And there was one that my friend showed me and he was like, Hey, Alice did this thing in the code and I don't get how this works. And I was like, oh, that's really clever. And we kind of worked through how it worked. And then a while later he said something of like, oh yeah, I went out and I, I hung out with Alice and we had a nice chat and I was like, I don't know who Alice is. And he was like, Alice, you talked to her for 20, 25 minutes at that mixer. And I was like, I don't know who that is. And he was like, she told you this whole story about this. And I was like, I don't know who that is. And he was like, she wrote that one function for finding the midpoint of an array? And I was like, oh, yeah, that's a great function. That was really clever. And he was like, that, Alice. And I was like, I don't know who you're talking about. I remembered the five lines of clever code. And I could rewrite that function from memory now a dozen years later. But I don't know anything about the author, even though I talked to her. I don't remember this woman at all. I guess my memory is just specialized from programming since I was a kid. So the programming stuff I remember pretty well. Everything else is just a blur. We'll get there. So what I want to say is that this should be a regular expression. And so I'm going to take that up to the model.

01:47:52Speaking of remembering code, the Rails API is so darn wide. What's the way I name a custom validation?

01:48:16Because I want to give it a function to say, oh, you're going to run this to make sure that it is a... We could just do it as a block, and I'll extract it later. I don't want to get hung up on the Rails API.

...50All right, that's the lowercase e. OK, and I don't have to pass the starting and ending slashes. Great. And if I submit something invalid, I get a exception. So I will just grab that. Does it call it what argument error? What am I rescuing? Regis error.

01:49:54e message right what's the that's my last exception now what's the What's the clever Ruby sigil last exception?

01:50:22It only works in the call stack. Dang.

...32All right, I will just do it.

...43Can I do it in line?

...51Come here.

01:51:00I want to double check that it's .message, really. Make sure I remember this API. It's much easier to just iterate in the console.

...26So I don't actually need to save it. I just want to instantiate. And if this passes, it's a valid regex, then there you go. Bob's your uncle. So where's the help label? There we go. I'm going to put that note on here that it's not you don't, it's don't include.

01:52:22All right. Does that get me to reasonable form? Good. Let me know if the font size gets too small on the browser or anything. I was just trying to avoid the wrapping. I thought the help text would get indented with it. Is there a nicer way? P class equals help. I never remember this. Markdown help label. I don't want to reuse that. It's very specific. That's okay. Mod forms can be a little ugly as a treat.

01:53:33I guess one of the things I'd also like to check is whether they are properly anchored to the beginning and end of a line. So I will have to check.

...52And I would rather force the user to do it than automatically imply them because that kind of edits your regular expression in a surprising way i would like to be in your face that also gives me more flexibility in the future not that i expect to have multi-line domains so maybe i just want to wrap with the beginning and end of line yeah yeah

01:54:58Don't want to have to deal with multi-line stuff. And then I'll automatically include the... I never... All right. Rails aliases starts with to start underscore with. It's kind of funny for Rails with its interest in plurals.

01:55:32What's the beginning of line? Capital A. Yeah. And then I'm going to say this needs an end. We'll make a kind of a wrap selector. It's an origin selector, right?

01:56:21I don't love moving this off to the other model, though. So we'll put it here.

...34So what I want is... Actually, I don't want rat. I want... Yeah.

...52And this can come down here. And I will do all of the clever bits here. So this doesn't need the slashes, but I want all of them to start at the start of the line and the end of the line. And what's the... Let's get zeal open. What's the... How do I pass the... that I want it to be case insensitive, because I want all of these to be case insensitive, because it's not worth messing around with. So we say options, and then do I pass it as a, okay, here we go, regex ignore case. So grab that.

01:57:59So that can create it. One of the nice things about writing error messages for programmers on an open source code base is every once in a while, I can just say, hey, go read the code. I don't actually have to explain what's going on. I can just be like, look, just go read the code.

01:58:55You know what? That's not really adding anything to what's happening. So we'll say that, and then frici bonus RTFM LUL
here's where the selector goes and all of these are yeah that looks nice to me yeah the bonus rtfm the other place i have one of those off the top of my head is we have rack attack which is a rails gem for rate limiting and some other stuff but primarily rate limiting And so there's this comment, hi, what brings you here? Because the default error messages that this prints or that I have written for this to print when people try and load too many pages just literally says like, hey, you need to call sleep one between your hits and you can read our source code config initializers rack attack so that the error message in this file Does that count as a Quine error message? where the file points to its own source. And then at the top, it has a comment of like, if you are seeing this because your RSS reader has an error, if you're trying to figure out about how the site works, just talk to me. If you are writing a scraper of some sort, that is most of what I have to deal with. Like that was the primary motivation for Rack Attack was, A lot of people write babies first scraper, and they're like, what site should I scrape? What would be interesting? Oh, I know. Lobsters has a bunch of interesting stuff. And then I get these really badly behaved bots that would try and hit us 30 or 40 times a second because we can respond fast to things, especially the cached pages. So I just had to nudge people to slow down a little bit.

02:01:05So with that, we have a syntax error. Probably that I don't have parents here and I see standard RB tried to warn me. I should have spotted that my single quotes didn't turn into double. I don't know if you're hearing any of that background noise. The cat just startled himself awake from a nightmare on the desk.

...52So just reload, not reload bang. Did Brails just not load? So no errors from standard. Yeah. Define local variable or method. All right, well, let's stop trying to reload and just grab the domain.

02:02:34And I guess we're going to say for the domain github.com slash, I guess we want to have a, we want to require that there's a named capture, right? Like you have to, I guess it doesn't have to be named. It could just be parents. So like anything that's not slash And there have to be multiple.

02:03:29Oh, it's not matching the HTTP at the start. Maybe I don't need that leading and trailing.

...52Now I'm into the fun of regular expressions of how many levels of coding do I need to put a backslash in front of these parentheses so they become a capture group instead of a literal character. like one for the string and one for the regular expression. This is not pleasant UI.

02:04:27So the slashes got automatically done and the A became a, it's not a, a needs to be escaped and then the z needs to be escaped because i'm trying to pass the backslash all right gotta reload let's grab the domain again really now you don't like reload you don't like it when it's

02:05:06Didn't like that I put a semicolon next to it to separate. I guess it's not actually a Ruby function. It's something clever in the prompt.

...21So let's match like that and then look at what we get out. We get a regular expression that starts with the literal A. This does not feel like it reloaded the code.

...46I know some people don't like regular expressions. I like them quite a lot, especially once I understood what was happening with finite state machines under the hood. The thing I don't like about them is getting the levels of quoting right for strings and for parentheses and for the various backslashes. That just kind of drives me up the wall. It's nice when languages include them as first class objects. But every time I do something like this, oh, I have to write a string and pass it in. It's how many levels of backslash? That's not my jam.

02:06:38No, but the input has to be correct.

...47So I have Do I have the correct level of back slashing? Maybe I have too much around the parentheses.

02:07:06There we go. So let's go ahead and grab this. and put it on the form because I am never going to remember it.

...44So if I have that, what I want is

...53a find or create origin that's going to say the identifier is, and we're into the weeds of the regular expression. Can I just say, I think I have to say dot match to get back a match data object that I can grab the name to capture out of. Yeah. And I'm wondering, do I want to force people to use the, what do I want to say? First name capture is identifier. It's a little limiting. but it's easier, it's simpler, because then you just put parentheses around the thing you want to capture in your set. Or we want to say it's a named capture, which is a little more explicit. I kind of like that.

02:09:19vinitkme Hello, Hello! is ~/.tmp/scratch just a normal file?
As defined right now, we can't sort out the github.com and github.io. Ah, hi, Vinit. I remember you from a couple of times ago. Yeah, Scratch is just my local Scratch file. I started this in the first or second stream where I wanted to compare options for implementing things. And it just made sense to lift something up from a comment to its own text file so I could refer back to it. And then it's kind of snowballed a little to, well, let's vinitkme Nice. super nice.
a list of topics that i'm going to talk about before the stream and then interesting links and these scratch files if you go to the stream archive each of these archive ones includes the scratch file up top so it's really handy if you want to watch back and refer to the notes or anything

02:10:40So we can match and then it's if there, so this becomes a match data and I can just look things up like that right now. It's not zero it's one. And if it doesn't match, this is probably an exception. Yep. Yeah. I don't know. You know, the identifier returned. So one thing here, one way to handle this would be to say, is identifier just the unique part or does it include site name? So if it's just the unique part, would be like foo in this example and if it includes site it would be github.com foo and the nice thing about the latter is that this could handle github.com verse because for io you would just write the regular expression arh68 i mean I feel all TLDs are more or less interchangeable
oh well it's a regex i'm trying to think like is there a way that on io it could just transform it yeah let me take the this the certainty out of it could this handle like i want to transform from i want the io to return github.com foo You feel a lot of TLDs are more or less interchangeable? arh68 like foobar dot com _is_ foobar dot net to me
vinitkme I just love your website and the sense of aesthetics you have. It has such a calming effect. Btw, I noticed, you have "Bhat" in your middle name, do you have some sort of Indian lineage? "bhat" is pretty common in India.
Well, if you feel TLDs are interchangeable, there is some exciting news on a WordPress in the last 48 hours. So there is wordpress.org, which is the open source WordPress software, and wordpress.com, which is a commercial hosting service. Both of these are owned by Matt Mullenweg, who is... Oh, I'm trying to pick my words very politely here. Having a contentious couple of days with WP Engine, an external commercial WordPress hosting service. And the accusations and the lawyer letters are flying pretty thick the last 48 hours. I'm not going to attempt to recap the whole thing because it's a big off-topic drama, but the gist of it is, you know, whether wordpress the volunteer project has much separation from wordpress the commercial hosting company and maybe they they don't so much so vinit kami thank you i appreciate the compliment and bot is not my middle name it is my last name and it is not just common in india it is my spouse's family name so if you've got a I have a blog post about this from when I got married. When I got married, we combined to a shared last name Bot Harkins. And man, there is this parenthetical note about poor programming. I wrote this in 2015 when I got married. oh that was prophetic every every quarter is is the ratio every quarter i run into another site or another service that cannot handle a family name with a space in it some or like a person who is just badly confused and has messed something up so i go to a conference vinitkme It's lovely to share both last name.
and they print out the name badges and half the time I'm under the Bs and half the time I'm under the Hs. arh68 ? "occasion of of" -> "occasion of" sry
Or one I've been fighting lately is the Firefox autofill assumes that my name is first name Peter Bot, last name Harkins. And I understand, you just have to guess heuristically on these things, but my family name is Bot Harkins. Occasion of, oh shit, you're right. ARH, that's a tight bell. arh68 also congrats lol
arh68 a little belated
man that come here where am i you catch any other typos also congrats a little bladed yeah thank you well you're not you're not belated you're just What, six weeks early for our ninth anniversary? Yeah. So I will... Yeah. So that should be live in a couple of seconds. There we go. Typo fix. Thank you, ARH. I appreciate you pointing that out. The typo fix is belated, but that one's on me, right? branimic is that inconsolata?
Yeah, it was funny. I went to the... Nah, that's not a story worth telling, actually. But yeah, it's just... Brainimic, yes, it's in Consolata. If you go to... I guess I need a FAC bot for it. But if you go to push.cx slash stream and scroll down a little here in the FAC, it highlights the... Actually, no, I don't need to paste this in the chat. The link is under the Twitch... But yes, it's inconsolata and operato sans. Operator mono sans. Woof.

02:17:09branimic cool, looks less blurry than in sublime text on windows
But Bennett, yeah, to come back to your question, we combined our last names as a very, very public sign of commitment to our marriage. It's kind of an enormous... arh68 naming things. kind of a big one
Well, not enormous, but it's a very big sign of commitment because it's, you know, updating every last piece of paperwork. vinitkme IMO, it's just beautiful.
It's been almost nine years and I still occasionally catch some account that has my maiden name. Yeah, naming things, kind of a big one. Yeah, there isn't exactly a domain model for people. Well, thank you, Vinit. I appreciate it.

02:18:02And I'm just guessing at how to pronounce your name. If you say Vinny or some other short version, you can just tell me and I'll try and remember that. vinitkme That just my first name.
So we're going to say, the other reason to have this scratch file is if I go on these digressions, it's nice to come back and be like, what was I talking about? Oh, right. I was talking about identifiers and how they should work. Okay. Yeah, I thought Vinit might be your name. Having spent some time in India now and having a whole bunch of Indian in-laws, I kind of recognize some of the patterns and some of the names. So the problem here is, as a regex, it doesn't transform. Like I could call .match and then grab the named capture and gsub, but that doesn't really match with the selector concept. vinitkme Ah, your wife must be from Gujarat or Kashmir. Congratulations to you both on your 9th, I will complete my 10th this december :)
At that point, I'm getting into putting arbitrary Ruby in the database and boy, does that, I'm not gonna eval code out of the database, even if it comes from moderators, that's just a bridge too far. Even pasting a... My wife is not from Gujarat or Kashmir. My spouse is from Bengaluru. I am aware that Bhat with two Ts is the North Indian version of the name. My spouse's family moved south about 800 years ago. They have the whole big family tree I've seen it so yes long ago and actually up until my spouse's father is the first one in the family who was trained as a priest but then went and started a career as I believe a chemical engineer he's been retired for a while so I don't remember what his job is but yes that's vinitkme haha.
are hitting all of the high points of the so you marry the daisy where everybody is like but you said bangalore but bod is a north indian name like i've had this conversation a few times and anyways congrats to you having your your 10th anniversary this december many happy returns i'm trying to think of what to do nice for my 10th next year I'm not great at romantic gestures, so good thing I've got a year to work it out. So what a hassle that no, this wouldn't include the transformation.

02:21:17So boo hiss. I might as well just grab the boo and then like vinitkme Not judging, just guessing. I will let you code in peace. You can gift her some Indian dress. Dress never goes wrong for girls :)
This is saying that origin is implicitly scoped to its domain. I'm okay with that.

...40Dresses never go wrong for girls. I have no eye for picking out clothing or jewelry. It is not a skill I have. So I will have to do something a little different. It is not so romantic to say, oh, here is a budget for picking out jewelry now. vinitkme The trick is to buy yourself without any help and hope it turns out to be good.
What I want to say is... Yeah, if it's just the unique part, we're back to... named capture or object.

02:22:57vinitkme But it's hard if you don't have enough context.
It's hard if I don't have enough context. Oh, the trick is to buy yourself without any help and it turns out to be good. That's not a trick so much as it is, you know, what that comes off to me with my general lack of fashion sense is the trick is to slam your hand in the car door and hope it turns out good. I just, I know how that's not going to go well.

02:23:28Can I call first?

...37There we go. So I'm trying to do the nil propagation operator here.

...52I suppose that's it. Anyways, Vanid, if you have better taste than me, Which is not a hard bar to clear. Congratulations and good luck. I feel like for 10, maybe I should do a honeymoon redux and we'll have a nice fancy trip or something. On the other hand, whenever we do a big trip, we go to India. Because it's like, if you're going to do a big trip, well, let's go see the family. And if we're going to fly for... 22 hours to get to Bengaluru. That's a big trip. So this is all pretty straightforward. Find or create. This kind of gives the burden of saving the origin to the color. And I think I'm OK with that.

02:25:01Yeah, I think I'm OK with that. We'll see how it goes.

...11And that's probably enough help text. I don't need to spell out everything about named capture, because again, all the moderators are programmers. That's going to be less useful to the sister sites. That's actually OK. Yeah. Hey, look, speaking of spammers. Oof.

...38Again, open signups make everything harder. Even if I get, what is it? Like the median number. I'm getting about one of those per stream. Or maybe one of those every five hours of streaming, it seems. Because they're not quite every single stream. And I stream for about three, four hours. Somewhere in there. Twitch does a pretty good job there. I'm surprised they can't catch those best viewer ones, especially because all they're doing is using custom Unicode that looks like the Latin alphabet, and you can get a lookalike table and smash that down, or just go, hey, anybody who's mixing character sets like this is automatically spammy, but I assume they are dealing with other fires.

02:26:33bluwumeaway does lobsters have any spam detection for text, kinda interested in how you would implement it but not seeing anything in my quick search
All right, so if we're going to have that, let's grab this example that worked. Oh, not that string. I want the regular expression I wrote.

...52Does lobsters have any spam detection for text? No. No, we don't. requiring people to be invited to sign up makes accounts valuable enough that people basically don't submit the kind of low quality spam like we just got that drive by here on twitch or you know best online viagra or something we don't get that as spam i think maybe once we got something like that but There was a April Fools a couple of years ago where I themed the site to look like PHP BB. And because there was a signup form in the PHP BB template, I figured just for funsies, I will turn it on. And we actually got spam bots that recognized a PHP BB signup form, and they submitted some of that garbage tier spam. got a couple of like normal new users out of it so it was an interesting experiment in opening signups but it did reiterate just how much spam is out there i would like to lower the hurdle of getting an invitation but that's a a whole another topic maybe we'll get to that next week or the week after i gotta get this origin stuff i'd like to improve some stuff for Making it a little bit easier to join the site, but then also easier to acculturate to the site, to learn the site norms and rules and how to participate effectively. I have some ideas for that, but, and this is one of the ones that's been percolating longest.

02:28:55So I grabbed the GitHub one and if I, and very Linuxy, I lost my clipboard. There we go. So I saved that.

02:29:26It is probably filling the cache for the replying comments view. In local dev, this occasionally happens that a page takes 90 seconds, two minutes to load because the replying comments view is slow to cache, especially when I have a dump of the prod database here. Let's see.

...58So I'm assuming that's going to say And I want to tweak this guy to say... I just know I'm going to have whitespace sneak in, so let's get rid of that. That would be no fun to debug. reason required for the mod log so the controller here is saying that it's only oriented to doing bands so i'm going to shift this edit and update over to well do i want to shift them over to custom actions or do you want to shift them over to another controller i've talked a bunch about how I've been trying to lean into the Rails conventions more.

02:31:11I think I do want to shift over to... Yeah, Kat, you got to be so loud with your collar.

...33a domain ban. Because if I do that, it's not domain singular, it's plural. Let standard rb fill in the stuff. So if I do that, They don't need their own form, but they can have this update method move over here. And they'll still have the find or initialize. They'll need that for all methods. They'll have domain forms. Path of form. This can move up. No, it can't, because the form is going to be same between these two. And then up in the domain view.

02:33:05This form down here, I think I could just do that to move the, let's look at it again. This might load, might not. I don't remember if form takes a controller action like that, but we'll inspect and we'll see where we get here. Oh, and I've got to make a route port, don't I?

...49I only need update because the other controller has the form.

02:34:07Yeah, that needs to be wider so I can actually read what's going on there, get a little cross-eyed. So that would take an ID, which is fine. Rails, why do you... I spend so much time mad at the way Rails does formatting. Okay.

...47This needs to have at least a placeholder. I'll fill it in in a second. So this looks correct to me. So if it's going to submit to the right place, we'll be happy. And then at the end, I don't think I can render another controller. I'll have to take a look at that. It might be worth adding a test for that, because now I'm starting to do something clever where it doesn't exactly match the Rails convention, even as I'm trying to match the Rails convention now. But this inheritance thing is a little different. So if I have the view and I try and ban without a reason, I just get nothing. It's not submitting correctly. Where are you submitting to? Form action. Yeah, didn't pull in the controller.

02:36:29So I have to say form action. Is that it? I thought I could put it on the form itself.

02:37:01So it wants the name of this route, which is going to be domains batch. All right, domains ban or update.

...22I think this is going to be update. But I don't see the name on. So I'm copying off of this update hat. Yeah. So I just want to say domains ban. And it'll get the right route from the verb.

...54Flip the form again, which let's swap that back around. There we go. So if I've got that.

02:38:18Yeah, I'm happy with that.

...26This one becomes update attributes.

...51So if I were to try and save with no message, I should get an error.

02:39:05Really getting driven to fix that delay. It's only minorly inconvenient to me personally, but what is it? The unread message count.

...29Stop. Now try. Just watch. I'm going to end up committing that.

...41does this because caching is disabled in development mode which makes sense but then what a pain it's part of why i lean towards One of these days I'm going to rewrite the replying comments stuff to remove the view.

02:40:16Good. It's up top instead of on the form, but I'm okay with that. If it's just update, not update attributes.

...38So we still have errors there. And then if I. What did I do with that? regular expression I wrote. Get this guy back.

02:41:42So with that, I think that's enough. It's a little boilerplatey, but that's fine. At least it's a short amount of boilerplate.

02:42:10I am... slowly accepting the nil propagation operator instead of requiring that people use try i used to have a rubocop rule to prevent it because i really dislike it but realistically so much of rails is about shoving around nils on mutable objects that I could either swim upstream and fight it all the time or just not do that.

02:43:17Ah, it didn't save. Have to look at that in a second. Actually, I want to look at that now.

...33Oh, it did save. It's just the form didn't present it again. That's odd. Oh, it's because I have the value that's not a default that was overriding the value, so you couldn't see it. That's all. I was thinking of the place folder. That's what I wanted.

02:44:08You know, if I have an example.

...32That's better text.

...53So how do I want to word this? So what I basically want to say is gets the form is fixed, but I want to print out this regular expression and say that we identify multiple origins. Oh, oh no. Well, what I wanted was to be able to print origins on the end here. So, all right, we're looking at

02:45:32we need to explain origins as a concept, and if this domain has any, and what are they, and story list detail needs to show origin for story, not domain. And the hassle here is,

02:46:07Does that want to become, we're back to recognizing github.com and github.io. So for something.github.io, it would be nice. So if this becomes an origin. how does this interact with identifier let's say origin.identifier we can't assume it is right we can't reconstruct that that's not useful i think the identifier has to show the user what the identifier is with the site name. So that's back to is identifier the unique part or does it include site name? All right. So with that, I'm going to take a second to run to the restroom because, you know, morning coffee. So I will be back in just a couple of minutes here and then we will fix that.

02:50:35all right i figured it out so one of the other reasons i wanted to step away for a second is it's harder to think when i am immediately at the keyboard and typing and it is much harder when i'm maintaining the pattern of or excuse me the pattern of streaming where i try not to have dead air but there is an answer to is the identifier just the unique part and how to handle github.com slash foo with regular expressions ruby has a really nice a really nice method called gsub that can take back references and i can do that so i'm gonna change the model. So let's jump over to, let's see, do I need this stuff? Let's keep all of this open and just open a new tab page. So on the origin, no, on the, I want it to be on the domain. Oh man, I'm almost wondering if I want to have an origin model at all, because right now it's just the output. So we'll have the selector that I kind of want to call origin selector to be clear, but there's no other selectors. We have a selector and

02:52:42I'm thinking of doing is bringing in this oh wrong keyboard shortcut bringing in and using string gsub which will take a pattern and a replacement and the replacement can include back references and there's A hoop or two to jump through to make sure that I don't let arbitrary string evaluation happen, I want to make sure that you can't. pass in a. yeah let's put let's make it to do here.

02:54:03So I don't want people to be able to pass in these Ruby escapes. I just have to double check that. That needs a test.

...36espartapalma Hi.. I joined late, not sure if discussed already: since the "origin selector" can accept regexp, should you use the timeout option of Regexp#new ?
Hi, Aspart, what's the timeout option of regex.new? I don't think I know this.

...57espartapalma ruby 3.2 added
I'm not seeing timeout here. Ruby 3.2 added. Oh, is my docset out of date? Yeah, it's 3.1. Let's see if I can grab the new one real quick. So I have a few doc sets. I'm just going to click on Ruby. Yeah, Cat, I touch your butt if you put your butt on the mouse. That's how this works. Cat gets offended when his butt gets touched. Like, what are you doing attacking? It's like, come on, buddy, you put it there. All right, so this, let's go back. Well, the title changed, but now it doesn't have a version. So we have a timeout. It's float value overrides the timeout interval. Oh, so it's just kind of a denial of service.

02:55:59espartapalma yeap... since is user input
I guess since I'm using user input, this is mostly, it's mostly trusted user input from moderators, but we might as well protect against errors. So do I pass it as I can actually see it jumping twice. Come on. So I can just pass it as a bar or as an option here. Where'd I go? So I have to say options and then let's say you get a generous hundred milliseconds.

02:56:58So you can do a string of options and I would rather just be explicit rather than have the eye there. I don't have to say the options keyword. Okay. I feel like it's obvious that this is options from context. Well, thanks, Aspart. That's a nice addition. espartapalma you are welcome
I hope it never triggers, but we can catch errors.

02:57:48So back here, we'll still select that. And then if we grab the select RxP, I think at this point, we don't need an origin model. Oh, yes, we do. If they're going to identify with an individual user or multiple users. Hmm. And at that point, it's just a. So maybe I'm going to just drop the origin model entirely, because what I want to say here is. Well, let's grab the selector rejects. We'll match it against the URL. Or no, and rather than match it, we'll say gsub with, ah, hold on. I'm getting this all out of order. It changes to say that it is the URL.gsub selector regex with replacement. So the idea is the identifier is going to be a unique string that comes from the selector and the replacement. And then up in the form that becomes a second field.

02:59:47and how many levels of escaping.

...59Yeah. scary just knowing how ruby strings work and how powerful gsub and such are but i like that i like that a lot the question is how many ways is ruby going to add to string that allow you to eval code because right now i can think of two and there are probably more with are probably more in the pipeline because if there's already two or three hmm we'll think about that so this we get a replacement we have an identifier

03:01:03Still thinking about that. Actually, rather than put the to do here, this is what I have the scratch file for.

...22So here, we'll just return the,

...36Yeah, I think that all just goes away. I'm going to leave this commented out for a minute because it may come back to this idea of an origin model as opposed to just a string. Yeah, we'll see. Kind of pushing the code around on my plate a little. So I've got to rerun that migration.

03:02:11And that's the, all right. I'm just going to go and manually drop that migrations.

...36Did I not call it? I called it selector.

...48OK.

...55So we have a selector. We have a replacement. We'll gsub stuff out. Let's kind of play with that at the console a second.

03:03:10Let's grab the GitHub. Let's say the selector is that.

...23Well, this is kind of the output.

...35Wrong number of arguments, line 38. Oh, I had to pass a URL.

03:04:00that's not what i expected because the regular expression didn't match yeah okay so that really needs to be so

...43Let's say blank, because empty string is also not useful.

03:05:06So we'll return the domain if the selector is blank, the replacement is blank, and then

...21if we have a thing we'll do that but

03:06:02you see where i'm getting here where i'm saying so if we're grabbing the origin for a particular url if there's no selector i'm thinking of this as just the string that'll be printed at the end of the story detail so that's yeah oh good syntax error i'll come back to that in a second the If there isn't a selector, which is going to be the default for all domains, we'll just return the domain string. Otherwise, let's try to match the selector. Why did it... Did I typo that? StandardRB swapped that in, and if there isn't a URL pass, that's an exception. Just from... Ruby is expecting one argument and then just make that origin. So if the URL matches, we'll return the string and then maybe that becomes the model. We'll think about that. And I guess what's happening here is I'm wondering how to handle the case where someone's regular expression doesn't recognize a given URL. So the case where if we have, like that's correctly getting recognized as github.com slash foo. But if we have slash bar, well, I tweaked the regular expression to have backslash z, which it shouldn't, because we're allowed to match partial URLs, and I guess we're okay with that. It should be anchored to the start. I'm okay with keeping that. So that was why my attempt in the console failed. The regular expression didn't Maybe I want to force the end align just to force people to be comprehensive. So rather than say the selector is that, it's, yeah, that's good enough. All right. Grab the domain. Set a good selector, set a good replacement. Yeah, I guess what I'm thinking about is the debugging story for these.

03:09:28Because even just doing this in the terminal is kind of painful.

...42And that's wrong. Should have grabbed everything that's not a slash. And instead it grabbed Everything to the end?

03:10:06That did not capture correctly.

...27All right, I think it's time to actually add a test properly, because this setup is a little much.

03:11:13Get that over on the side so I can see what I'm doing. One of my hangups is I always want the code on the left and the test on the right.

...53Let me split that to multiple lines. Let's see where we get in a second. And once again, I want to grab this regular expression back to my clipboard. Yeah, let's get onto multiple lines.

03:13:11It's not going to pass, but at least now I've got a nice little test harness so we can just see the error over and over.

...26I think the maybe what I want is a button in the admin UI so that the moderator who is editing this can click to run this code against all of their domains that are in the database, all of their URLs that are in the database. When is this test taking so long? Was that timeout of 0.1 measured in weeks? Oh, it's the test database would have had to run the migrations. I bet that was it. So we expected... GitHub foobar to equal git foo. Didn't get it. So it's a bug in the replacement, right? Yeah, it's the regular expression. I have to match everything so that I can throw away the other parts, because otherwise it's just doing...

03:14:36It's taking... Gsub is only replacing the parts of the string that match.

...59Yeah, that's a little clunky for interface. So this I would have to change to move this here. And then just match everything else. And then this becomes like that on a pass, but I don't like writing that regular expression.

03:15:30Yeah. It feels not great, right? where I'm not, I don't want to gsub, I just want to get the named capture once again. But I do want that replacement a little bit, where I want to replace the whole string

03:16:13So I'm looking at the substitution methods on string, and there are a couple. First off, I want sub, not gsub, because there should only be one match per string. gsub is so much more common in actual use that I just defaulted to it.

...48What I really want to do is not replace sections of a string but replace the entire string with something that has the option to use back references.

03:17:13But I don't think there's a way to do that.

...20At which point it's just got to be this.

...39So we'll say like that. And then match the rest.

03:18:06And I guess at this point I'm adding back that backslash C I suggested because you're going to get very surprising things if you don't match the whole thing.

...26If this was a general purpose tool for non-technical users. I don't know how I would ever get a reasonable UI on this. At least I can assume my users know regular expressions.

...54There we go. That's a stream title there. So we'll say we'll match, we'll do a sub. And I would like to know, yeah.

03:19:10Again, I almost want to return nil there so I can indicate it, but let's see how that goes. Does that test run?

...27yeah and you have the option of using pipe in a regular expression so you can match multiple shapes it gets a little it gets a little painful with the implied backslash a and backslash z surrounding because you'd have to include the intermediate ones and not the external ones so maybe i just want to validate that you include those

...57doesn't start with, it doesn't end with,

03:20:20So if I mandate that, we're just passing the selector with no interpolation happening. And here, there's a Rails foot gun happening here where the test is now creating a domain with an invalid selector because it doesn't start with the A and end with the Z. But the code can't know it. It is in an inconsistent state. It has to, if I wanted I would have to, like, run a validator. So, like, call valid and... Yeah, there's this weird thing where because Active Record objects spend so much time in invalid states, often that are generated by applying user input to a record, which is kind of scary. every method like origin here has to know that it's possible for it to be in an invalid or a partial state and this adds a ton of complexity or you end up with pain where it's like does the shopping cart work with these functions and these helpers and these templates and you just have to go ask the person who knows that code cold because they have loaded in their head the invisible state machine of which methods work on partial and invalid records. It is my least favorite part of the active record paradigm. It makes active record really easy to get started with, but very painful to work with. Because here, if I didn't think to include this, this test could go ahead and run on invalid data that you could never see in the real world. And then just painful.

03:23:01All right. So that passes. That's a valid regular expression and replacement.

...19Actually, we already have that validation of you've got to start with the A and the Z to consume the whole string. That feels okay.

...33So that gets us a string. Come here.

...52And if we got a string, we could show it on the page, right? Let's take a look at that. If we have the story list detail, stories, plural. And on this one, we say if there is a domain present, We will link to, let's just say, I'm going to just call story.domain.origin with story URL. We'll just kind of print this out for now and see where that gets us. Let's print it after. Let's print it instead of, I'm going to edit this file. So wrong window. Give that a second to load.

03:25:04Still have a syntax error. What's my error? In for domain.

...14It's mad about the template. What do we got here? Got this new code.

...31Let's just delete that. Let's see where it gets us. All right. Not immediately erroring out. Now it's just doing that long pausey thing because it doesn't have the cache. Sit over here. Yeah, after the query finishes, it'll print the name of it. And it'll say like, oh yeah, this took 20 seconds to run. Some ridiculous thing.

03:26:02Where is it?

...32So that ran and did not print anything like what I want. Why?

03:27:16Hmm.

...58This detail here is supposed to say call story origin. Oh, it's I got the. I got to grab these values. I got the test working, but I didn't put it in. And then I have to remove a layer of escaping, right?

03:29:01Unexpected return. I'm not allowed to return out of the block.

...19I think this just might result in having an extra regular expression error, but... Oh, the It's the levels of quoting thing again. So let's reload that form just to make sure I got a fresh version of it.

03:30:03The levels of backslash escaping is getting a little tiresome. Send this guy.

...19It should be correct. Yeah.

...30I don't need the extra backslashes. And this can be backslash. Save.

...49So there's a primitive obsession thing happening where I am sort of implying that an origin is a string as opposed to a model. And right now it is, it's just that replacement.

03:31:13I hope text is wrong again, because I keep editing what it means to be a valid regular expression.

...34What did I do in the controller that that saved but didn't? Come here. Now I'm wondering what state I'm in. It presented this again, but I didn't get any errors.

03:32:03It did not save. But it didn't have any errors. And there isn't any validation there on the replacement. So I'm putting that on the list because I'm coming up to an appointment and I'm going to have to stop in a few minutes.

...41Well, here's a good chance to play spot the bug and see why does my controller not have, or why does my view not have any form errors? Let's go look at that view.

03:33:10There's nothing here to print that error. Is that all it is? Because I literally don't have a, how did I see that error for a ban message, though?

...30Oh, it said the flash. That's what it is. That's what's missing from the domains controller.

...56Oh, where's the, sorry, just say success.

03:34:10And then it's,

...25Just setting the flash in the error code.

...38Just two lines. There we go. I believe the way this is set up, it should print the form errors for the model. Let's check on the Stories controller.

03:35:12Edit, or we'll just re-render the edit form.

...39So we have an error, but we don't have the flash with all the info.

03:36:02And I'm blanking on the.

...10how to get the model attributes all listed.

...22So you're editing a story.

...50Ah, there's the form errors. That's what it is. OK.

03:37:09So this form needs to have the errors for the domain.

...20And I don't think I need to have a flash at all, because if I just have the inline errors, that's plenty. As long as I'm here, how about some spacing around that? Yeah, we're going to add spacing like it's 1999.

03:38:06Come on, tell me my error. Oh, I put the wrong. This is the selector. This is the replacement. So I was overwriting this in the form because I had the wrong thing.

...37We could keep a counter how many times I have had to add and remove a layer of escaping. And that counter would also be the number of gray hairs I have gained this morning. And again, there's missing backslashes.

03:39:12Where did this come from selector invalid back graph number slash name Oh, because it tried to instantiate the regular expression. And I can't return out of this block there's.

03:40:01Okay, so I want to do that style.

...10Let's validate with

...32Now I can return because it's a method instead of a block. I just want to be able to bail early. I don't need extra errors.

...52So this error came back because I didn't reload the form for the fixed

03:41:06for the fixed form input name. So there's one more gray here.

...59That seems pretty good. OK. Assuming I get something reasonable. All right. How have I messed up this form?

03:42:17And you know what?

...38I'm kind of dying with slow loads on that because I keep getting tempted to go fix other things and then I get distracted and then I come back and something else is broken and so I'm not spotting what is going on with this selector and replacement and this form that's not actually editing the right thing. The ID is selector but it's going on the Params? I bet it's... I didn't update the replacement as a valid field. So I don't know why I didn't even get an error there.

03:43:29All right. So we're kind of in the middle of this, but basically the outline of this works. And then origin, if I want to have a model, it can many to many users to kind of replace the authorship flag.

...52And the point there is getting at, oh, github.com slash pushcx. That's me, which I can do that one by OAuth. But then others like my blog, it would be nice to tag. This is my site. I'm affiliated with it. That would help also for new users of it could prompt them and say, Hey, is this your site? If so, we'll just kind of add that. Yeah. So that's where I've gotten to today is working through these design issues, getting the to do.

03:44:33arh68 PopGhost have a good one y'all
Don't need that addition but i'm going to wind up the stream here because I need a couple of minutes to get up to my one o'clock appointment, so I will thank you all for tuning in and if you have any last questions you can ask in about five seconds but. With all this hassle with regular expressions I. ran a little longer than I want to even. frici Thanks for the stream, catch you next time folks πŸ‘‹
All right, everybody's chill. So we're going to say goodbye. I will see you again on Monday, which is what? pushcx See y'all Monday!
September 30? Last day of September? Yeah.

03:45:15bluwumeaway cya
Thanks again for coming by. Take care.