[–] 5 points 1 week ago

I've come around to this position after seeing the mess people make.

I just got a new job where I contribute to a fancy open source database. They do have unit tests. Barely. Most things are tested in SQL though. You have to build/link the whole thing to run the tests. But lots of things are plugins so it's fast enough.

If you can get away with it, this is better.

  • source
  • parent
  • context
  • [–] 4 points 1 week ago

    The way Ghibli's villains work says something special to me.

    The ultimate villain in Howl's Moving Castle isn't the Witch of the Wastes or the heart eating fire demon. It's the court magician causing a war.

    The ultimate villain in Spirited Away isn't the uncaring parents or the dragon no one trusts or the scary spider dude or the grumpy frog guys or the giant baby who hurts Chihiro or even the greed demon. Or the woman who tries to kill the love interest. It's the woman what owns the bath house.

    In Porco Rosso the villain isn't the air pirates who kidnap children or the asshole rival ace or Porco's last male friend who joins the fascists. It's the secret police. It ends with everyone making peace to flee the fascist Italian Air Force.

    In Castle In the Sky the air pirates are big softies. The villains are the military and the intelligence officer with the nuke.

    That isn't to say the other villains aren't bad. The air pirates shoot up a town and rob people. The Witch of the Wastes is cursing everyone. Noh Face eats people! But they are redeemed in my heart. I'm not entirely sure why. Maybe because everyone lives after Noh Face vomits them up. Or because the air pirates can't hurt the kids they kidnap.

    I love The Witch of the Wastes. She never stops being bad. Never stops hurting people. The state cripples her and she still fights back. She fights everyone. Hurts Calcifer. Taunts Howell. She's so angry. So broken. If she had the power of the state she'd be worse than Madam Sullivan. But she doesn't.

    Porco doesn't look at the camera and say, "It's better to be a pig than a fascist." The whole thing just.... Says something. To me at least.

  • source
  • parent
  • context
  • [–] 5 points 2 weeks ago

    I just that with my kid and it for some reason I laughed so hard my kid thought the whole thing was funny. It's just so absurd and terrible and wonderful. He's this nightmare murder dude in a kids movie.

    It's genuiy terrifying. But I made it fun for my kid somehow.

  • source
  • parent
  • context
  • [–] 2 points 3 weeks ago (3 children)

    I genuinely love the idea of the $1 after a match. It feels so natural in perl! So many things are text matching.

    But! But! But!! Those $ variables are dynamic scoped! If you call a method and it matches stuff you lose the variables!

    I'll bet there is a way around it. But it made me so sad.

  • source
  • parent
  • context
  • [–] 2 points 1 month ago

    Wikipedia has a search feature. Not many people use it, but Wikipedia is huge, so enough people do. Back then, a couple dozen full text searches a second. And maybe 100 quick prefix searches.

    Anyway, one thing I made for it was a way to search the wiki text with regular expressions. It's useful for maintainers.

    Wikitext is the funny markup language Wikipedia uses. If you know html or md it's like that, but it can kind of "call" other pages. Whatever. Doesn't matter. It's text. And people have strong opinions about it.

    You can see it by clicking "edit" (sometimes looks like a pencil) and then clicking "edit without logging in" then "source editing". Those lovely boxes at the top for a person are made with something like

    {{Infobox person
    | name               = Douglas Adams
    | birth_place        = [[Cambridge]], England
    }}
    

    Imagine you have 1000 articles that use birthplace instead of birth_place. Both work, but it's driving you and all your editor friends crazy there are two ways to do it. This is believable. Trust me.

    You want to find every page that has an {{Infobox person followed by birthplace. Then fix them. The nerds who came before us invented a language to ask that question called "regular expressions". The one for this looks like \{\{Infobox\wperson.+birthplace. Maybe. Nerds will know regular expressions are bad for this. But nerds will also know that regular expressions being bad has never stopped anyone from using them anyway.

    One way to run these regular expressions is to convert them into an https://en.wikipedia.org/wiki/Nondeterministic_finite_automaton . You build these in memory and they are not big. But you can't really run them directly. They are pretty and fairly easy to read once you get used to them. But you can't easily ask "does this match this text". At least, not with the tools I had.

    I could only run https://en.wikipedia.org/wiki/Deterministic_finite_automaton . It's deterministic! Much nicer. And you can go from a nondeterministic one to a deterministic one. Easy. Our forenerds solved the problem. You use a https://en.wikipedia.org/wiki/Powerset_construction .

    The trouble is, it can make very very very big deterministic finite automata. Like, if there are 3 states in the nfa you can get and 8 state dfa. 4 is 16. 5 is 32. In the worst case. Usually you get much better. But a fairly big but not super frightening regular expression can turn into a big nfa. And the dfa would need more states then there are grains of sand on earth. Too big for computer.

    So, user asked for this regular expression. The search servers tried to convert it, and filled up their memory and died. They ran Out Of Memory. OOM. The usual thing is you copy the full memory so you can look later and start the server again.

    But that can take time. And sometimes people are confused and haven't set up the restart to be automatic. And they can't find you. So search stays broken for a while.

  • source
  • parent
  • context
  • [–] 8 points 1 month ago (2 children)

    Tooks out search on Wikipedia. I exposed a path that can perform an unconstrained Powerset Construction concurrently on 7 servers. It filled up memory and died. User retried. While cluster OOMing.

  • source
  •  

    I just finished Prophet Song and loved it but I want to rant about the second sentence. Here are the first three:

    The night has come and she has not heard the knocking, standing at the window looking out onto the garden. How the dark gathers without sound the cherry trees. It gathers the last of the leaves and the leaves do not resist the dark but accept the dark in whisper.

    The first sentence is great. Introduces the setting and the tone and tells the reader, "I'm about to play with standard grammar."

    The third sentence is, like, one of thesis statements for the book. Lovely imagery. I wouldn't have written it that way but I'm not a poet and I'm sure there's some meter I'm missing.

    But the second sentence is clunky. It reads like he forgot a word. He didn't. If you read it as "How the dark gathers, without sound, the cherry trees." then it's fine. It links to the next sentence. But I read it as "How the dark gathers without sound the cherry trees."

    I ran an informal servey at a board game night and no thought this was a sentence. They did not understand.

    So here's where my rant begins: he knew I'd do that. He demonstrates profound ability to control how you read. And he absolutely can write grammatically illegal sentences that are super readable and compelling. He's good at this shit.

    He goes back to the cherry trees over and over again in the book and it's comforting to check back in on the tree metaphor. It's a wonderful, comforting metaphor for suffering. You get to high five it a bunch of times during the book. It's important you remember the trees.

    And I sure did! Because of that clunky second sentence I showed my friends. My wife said, "only a white guy would dare write like this." And, I dunno about only but his choices do scream, "I'm a pretentious Irish poet and this is Literary Literature."

    He knows people are going to say, "this dude wishes he was Joyce" and "he sure ain't Cormac McCarthy." Again, he's good at this shit. I think he wanted to do a Literary Literature about refugees.

    Back to cherry trees. I think he chose to make that sentence flow so badly that it stuck in your craw so you'd remember the stupid trees. Talk about them. I think this is a thing Literary types like to do. To put ideas in your head using these fun meta tricks.

    And it worked! I'm talking about the damn trees. And if you read the book and are reading this you are being reminded of the trees and the peotic thesis. I think this is intentional. You don't risk the second sentence of your book being clunky unless you know what'll happen.

    But was it worth it? I almost put the book down. I've never read this dude before. I almost gave it back to the library on page three when I realized he wasn't doing paragraphs. I'm ok without quotation marks. Didn't bother me.

    I read an interview where he said he felt like Europeas just weren't getting the refugee crisis. I've seen people criticize him to telling this story in Ireland or telling a fictional story when so many real life stories happened in the 30s. And much more recently in Eastern Europe. But I don't buy that criticism. He's correct that Europeans don't get it. Well, I know Americans don't because I'm here and ICE and shit. But I've seen some y'all's media and it sure looks like you are in the same boat as us.

    Whatever. He may as well give it a shot. If tarting it up with metaphor and Literary Literature gets the message out then great.

    But if you want to get the message out then why risk the clunky second sentence? Is it not clunky to Literary Literature types?! If it isn't clunky then I'd have expected him spend another sentence or two of the trees. Can't high five a metaphor you forgot.

    So I think this is intentionally clunky. And it does help me remember the tree metaphor. But maybe it does more? I certainly showed it to a bunch of folks. But the lack of paragraph breaks dominate the conversation and he had to know it would. He's good at this shit.

    Ideas? I'm obviously overreacting. But this is an important choice! One that I don't understand. I don't understand lots of stuff and it doesn't usually bother me. Why does this sentence bother me?

    What is literary fiction? (programming.dev)
     

    Could you explain literacy fiction? I come from scifi/fantasy land and am confused.

    There's this definition that feels like "genre fiction has some recognizable theme/trope/rule/setting/whatever. Literary fiction is just the stuff that doesn't fit easily." I guess that's a fine definition. Useful! Though I think my library just calls that "fiction" or "general fiction".

    But there's this other "literature makes you think" definition. That's the definition I feel like people mean when they say the word with reverence. There's some "genre is popcorn and literature is vegetables" there too. Genre is of plot driven literature character driver. Literature examines the human condition and has complex story structure.

    So, like, Use of Weapons and Chasm City are just about the most scifi books to ever scifi. I'm not as into war fiction, but Catch 22 counts, right? They use they're complex narrative structure to make you feel a way. In service of their examination of war/time/identity. I dunno. Slaughterhouse Five leans on scifi to process war.

    Never Let Me Go uses it's simple structure and scifi tropes to examine a very complex theme. That book is not candy.

    Ender's Game taught me more about empathy than religion ever managed to.

    There is certainly plot driven scifi with not great characters that's super duper scifi. Three Body Problem, 2001, Childhood's End. I don't tend to like those as much. But they sure have things to say about the human condition.

    We're living in some terrible mashup of Snowcrash, The Diamond Age, Neuromancer, and The Fifth Season. And they wrote those books because they saw it coming. Or wanted to explain that I was already here. Hell, there's even the classic "we built the torment nexus from the classic book don't build the torment nexus" meme.

    I'm just.... What even is literature?

    view more: next ›