• 4 Posts
  • 323 Comments
Joined 6 years ago
cake
Cake day: May 31st, 2020

help-circle

  • At its core, SystemD coordinates and launches all the services in your operating system. So, it is essential for the boot process, but also does scheduling, meaning you could run a backup script every night with it, for example.

    That’s the simple answer. But in truth, SystemD is often criticized for doing too much, so it’s hard to describe what it really does. For example, you can also manage network interfaces via SystemD.

    Kind of the goal of SystemD is to provide common plumbing which works the same across distros, so that when you configure your services or network interfaces etc. on Ubuntu, it works the same as on openSUSE or Arch or whatever.




  • Yeah, my current software project at work was basically half a year of feature development and since then, we’ve purely tried to get it into the real world, which meant evaluating use-cases to see where it falls flat and what needs stabilizing, as well as figuring out people’s needs and how our software can assist with that, then setting up a demo and hoping they find money somewhere…


  • Ephera@lemmy.mltoGames@lemmy.worldPet Peeves with Games?
    link
    fedilink
    English
    arrow-up
    2
    ·
    10 days ago

    I think, this was on my mind: https://pt.mezzo.moe/w/waYE4NkZGpqQ9qpW1th1ga?start=15m10s

    I don’t know, with this example in particular, I find it quite disruptive, too, that there’s explanations of the game mechanics and then the character barges in with some funky expression and some rhethoric question à la “And then I’m that thing?”. Yeah, dude, did you not listen to the tutorial ghost explaining that just then?

    In fairness, this is a game that’s pretty much story-first with a bit of puzzling in between. And it was only that Let’s Play that I saw; I would’ve almost certainly skipped that game, if I came across the store page, since I assume, it would’ve been obvious that it’s a story game.
    Well, and also in fairness, this is a pretty fringe game. There’s a decent chance that it isn’t considered ‘good’ in other aspects either.

    In general, I don’t want to be too critical. Not every game has to be for me. Well, most don’t have to be, since I don’t play an insane variety of games to begin with. But yeah, still just wanted to throw that into the conversation as a pet peeve of mine, since there’s (perhaps less egregious) examples of that in a variety of games.


  • Ephera@lemmy.mltoGames@lemmy.worldPet Peeves with Games?
    link
    fedilink
    English
    arrow-up
    1
    ·
    11 days ago

    I think, you’re perhaps conflating story with gameplay here? I do think, it’s good to incorporate the tutorial into normal gameplay. So, you start playing the actual game right away and get told the controls as you need them. And sure, if it is a story-driven game, that probably means there has to be a story segment before all that to explain why you’re starting on this journey to begin with. So, I’m not saying I want the tutorial to be an entirely separate thing, like it typically was in the 90s.

    I’m mainly just complaining about when it’s too intermixed, because I’d like to be able to skip all the text boxes where they’re rambling about the story. If they switch mid-sentence to explaining what you’re supposed to do and what buttons to press, then I’m likely to miss that while skipping through the story bits.
    Preferably, there’s a separate info box on screen after the dialogue ends (which is a good idea for several reasons), but it could also just be highlighted, if they want it to be within the dialogue.



  • Ephera@lemmy.mltoGames@lemmy.worldPet Peeves with Games?
    link
    fedilink
    English
    arrow-up
    3
    ·
    11 days ago

    I really don’t like when games intermix tutorial with story. Unless the story is the main attraction, I cannot get myself to care for it. And then having to click through tons of story texts to pick out the tutorial parts, that is just cumbersome.

    I also have to say, though, that it really doesn’t help my immersion when the fairy, that just told me she’s from the clan Uhgaloogah, then tells me to press the X button on my controller.
    If you put in a lot of effort, you can make it credible that the controller is part of the game world and the fairy would know the buttons. But most games do not put in that effort. And then, IMHO it is a lot less immersion-breaking when the game just shows an info box, where we both know that it isn’t part of the game world.


  • My problem was that “Albert Heijn” is a dude’s name. It does not exactly scream “we’re talking about a real physical building”.

    For all I knew, the impossible problem we’re solving could’ve been on a mathematical plane, named after mathematician Albert Heijn. “Sweeping” just as well can be used in an abstract sense.

    Obviously, I did think of physically sweeping a physical floor first and foremost, but especially with the rest of the blog post being so entirely abstract, I had doubts on that for far too long, which did not make it easier to understand.





  • In many cases, you don’t need an equivalent to finally, because the cleanup is automatically handled via the Drop trait, which runs cleanup code when the object is freed from memory (similar to “destructors” in some other languages).
    Because of Rust’s whole ownership thingamabob, it’s generally entirely deterministic when this code will run (at the closing brace for the scope in which the object is defined, unless you pass that object outside of that scope).

    In other cases, you don’t need a finally, because nothing forces you to bubble up errors instantly. You can make a call which fails, store the error in a variable, run your cleanup steps and then return the error at the end of you function.

    Sometimes, however, you do want to bubble up errors right away (via ? or early return), typically so you can group them together and handle them all the same.
    In that case, you can run the cleanup code in the calling function. If you don’t to want to make it the responsibility of the caller, then pull out a small function within your function, so that you become the caller of that small function and can do the cleanup steps at the end of your function, while you do the bubbling within the smaller function.
    There’s also ways to make that less invasive via closures (which also serve as a boundary to which you can bubble errors), but those are somewhat complex in Rust, due to the whole ownership thingamabob.

    I will say, I do sometimes feel like Rust could use a better way to handle doing something before the error bubbles up. But generally speaking, I don’t feel like a finally is missing.


  • You can use the anyhow crate for something quite similar to exceptions: https://crates.io/crates/anyhow

    In terms of how it actually fits into Rust, you want to use anyhow for application code. If you’re writing a library, then anyhow is a no-go, because users cannot match on different error classes with it. (Much like you would want custom exception classes, so that users can catch them in different catch branches and handle them differently.)

    Every so often, you will also need matchable error classes within your application code, then you would have to replace anyhow with a custom error type there, too, of course.

    I will also say, IMHO it is fine to use anyhow even while you’re learning Rust. It is so easy that you kind of skip learning error handling, which you will need to learn at some point, but you can still do that when you actually need it.



  • We deployed a client software in a Docker container on Windows 10. It could not connect to the backend, even though we saw SYN packages originating from it.
    So, we ran WireShark on the Windows host and saw that the SYN-ACK packages from the backend were arriving there, too, but no ACK came through to complete the TCP handshake.

    Eventually, we rolled out a network debugging container on that Windows host and then could see in the tcpdump, that the SYN-ACK packages, which arrived on the Windows host, just did not show up in the container. Hyper-V or something was quietly dropping them.

    Other network connections were working fine, just the SYN-ACK from our backend triggered this.