Anon questions physics
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    4d ago 100%

    There's a bit more to it, but it's because of this effect.

    There is actually a balance between liquid and gas state, just overwhelmingly in favor of liquid when at normal temperatures. There is a ratio of molecules that will hit each other and transition to gas, and an equal amount gas hitting liquid and condensing. At least when there is a balance between the two sides, aka 100% moisture in the air. Which is not how it is most places.

    Normally there is always evaporated water in the air, and anything that evaporated will be moved away in any mildy ventilated area, as you say, it leaves the system. So it never reaches a balance, which is why things dry up at lower temps as water will always evaporate and leave the system.

    9
  • Bcachefs Fixes Pull Once Again Frustrates Linus Torvalds - Two Choices Offered
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    2w ago 100%

    If you're so convinced you know best, I invite you to start writing your own filesystem. Go for it.

    Dude is seriously missing the point here. It's not about what, it's about how.

    52
  • Avoiding if-else Hell: The Functional Style
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    4w ago 100%

    What's fun is determining which function in that list of functions actually is the one where the bug happens and where. I don't know about other langauges, but it's quite inconvenient to debug one-linres since they are tougher to step through. Not hard, but certainly more bothersome.

    I'm also not a huge fan of un-named functions so their functionality/conditions aren't clear from the naming, it's largely okay here since the conditional list is fairly simple and it uses only AND comparisons. They quickly become mentally troublesome when you have OR mixed in along with the changing booleans depending on which condition in the list you are looking at.

    At the end of the day though, unit tests should make sure the right driver is returned for the right conditions. That way, you know it works, and the solution is resistant to refactor mishaps.

    6
  • When lemmy.zip was announced, a few people were concerned about the .zip, as it could create security issues. Has it been the case so far? Has anyone ever been blocked by a work firewall due to .zip?
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    4w ago 100%

    They are just more likely to be scam like, particularly since they can be assumed to be a file at a glance.

    Even more deviously, crafty urls like this further hides what you are actually doing, like this:

    https://github.com∕kubernetes∕kubernetes∕archive∕refs∕tags∕@v1271.zip

    Hover it with your cursor, watch what that actually links too, no markup cheating involved. Anything before the @ is just user information. Imagine clicking that and thinking you downlodaed a tagged build, only to get a malware?

    It's not the end of the world, but as a developer it makes great sense to just auto-block it to avoid an incident. The above URL is from this article, which says it's not as big of huge problem too:

    https://www.theregister.com/2023/05/17/google_zip_mov_domains/

    But it's kind of a death by a thousand cuts to me, because it's another thing with another set of consideration accross the internet ecosystem that one will have to deal with.

    17
  • Asgard launches world's first DDR5-9600 CUDIMMs — promising DDR5-10000+ modules are on the way
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 100%

    I'm not sure if latency is much of a thing with DDR5 compared to earlier gens, but 9600 MHz at CL44 is comparable in latency as 6400 MHz at CL30. The former with a latency of 9.167 and the latter having a latency of 9.375. So a slight imrovement to what I can see is one of the better choices currently available, so they seem like something worth buying if the price is reasonable.

    For AMD the frequency matters more (there are sweet spots for their CPUs), but these do not even support AMD Expo according to the article, so currently these are only worth using with Intel anyways.

    3
  • Do You Still Use Git in the Terminal?
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 100%

    I am more than happy with Jetbrains and Visual Stuido to do most of my work. While VS has some annoying irks, I just like things more visual such as handling merges through seeing the code as I used to instead of a text like visualization.

    I do occasionally need an empty commit, visit the reflog because I fucked up or just do some check on existing commits on a branch. But no, daily I just do pull, merge, commit and push through my IDE.

    1
  • People who lived in an HOA, what was your biggest nightmare with them?
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 100%

    Norway has something similar, you own the inside usually and the HOA own the outside, including the houses themselves. Live in one, largely a good thing but some things come slow since they need to be voted for of course. Generally worth it, since you get good deals on things like internet. It's cheaper but it's also something you usually have to use and the only option. Eg only that provider of internet.

    I'm my case, they are also responsible for my balanced ventilation, my exterior doors and my water heater. So when the time comes, they handle it. Shared costs cover snow plowing, the shared community building, upkeep of garage, outdoors and the buildings, and things like water bills and taxes paid. In particular, HOAs purchases do not need to pay a 2.5% of the purchase price fee when you purchase a home. This itself saves you quite a bit, and makes up for some of the extra you pay in monthly costs. (but pretty much all of those are at least going somewhere that benefit you anyways)

    The downsides are, there are special rules so some people that have membership may have a right to take over the winning bid in a sale. I myself used this to purchase my place, having gotten 10 years of seniority in "HOA company". You spend the seniority with your purchase, but also are not allowed to own more than one part. Also, no long term renting so there aren't any companies buying and renting out and things like that. You have to live in the HOA.

    2
  • Why I Prefer Exceptions to Error Values
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 66%

    But nothing is forcing you to check exeptions in most languages, right?

    While not checking for exceptions and .unwrap() are pretty much the same, the first one is something you get by not doing anything extra while the latter is entirely a choice that has to be made. I think that is what makes the difference, and in similar ways why for example nullable enabled project in C# is desired over one that is not. You HAVE to check for null, or you can CHOOSE to assume it is not by trying to use the value directly. To me it makes a difference that we can accidentally forget about a possible exception or if we can choose to ignore it. Because problems dealt with early at compile time, are generally better than those that happen at runtime.

    1
  • Why I Prefer Exceptions to Error Values
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 80%

    It can be pretty convenient to throw an error and be done with it. I think for some languages like Python, that is pretty much a prefered way to deal with things.

    But the entire point of Rust and Result is as you say, to handle the places were things go wrong. To force you to make a choice of what should happen in the error path. It both forces you to see problems you may not be aware of, and handle issues in ways that may not stop the entire execution of your function. And after handling the Result in those cases, you know that beyond that point you are always in a good state. Like most things in Rust, that may involve making decisions about using Result and Option in your structs/functions, and designing your program in ways that force correct use... but that a now problem instead of a later problem when it comes up during runtime.

    3
  • Music industry’s 1990s hard drives, like all HDDs, are dying
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 100%

    If I had a cent every time an artist on patron had their computer die on them and lost works in progress or all their old stuff... I'd afford a few coffees.

    15
  • games
    Games 1mo ago
    Jump
    After 350,000 signatures in an EU consumer rights campaign, Ubisoft is adding offline modes to The Crew games - but not the now-dead original
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 100%

    I think Destiny is a good argument. If D1 ends, then playing starting D2 won't be the full experience. And new players can start many years into a game. D1 is also stuck on a console, while D2 is so big they removed content from it. You literally can't play the base campaign in D2, a huge part of the story is no longer there. A great game that "you had to be there" to play.

    It's the extreme case but leaving games to die instead of having at least the chance for private servers is sad and a loss for everyone long term that don't get a chance to play it.

    8
  • Programming.dev instance: Sponsors needed
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 100%

    If Reddit back in the day had asked a few dollars for me to stick with using 3rd party apps using the API I would have. But they did the opposite, so here I am. First time actually donating to something, a measily $2 dollars a month, but hopefully a start to fund some of the free stuff I use.

    36
  • news
    News 1mo ago
    Jump
    Trump rebrands his ramblings as ‘I do the weave’ – but is he just losing it?
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 97%

    I still find it amazing people believe the same constant child like lying.

    Everyone says... A close friend of mine said... A professor said... Everyone knows...

    ...That I have the bestest (health/speech/IQ/humbleness/big hands)

    37
  • Good Refactoring vs Bad Refactoring
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 100%

    I largely agree with this nodding along to many of the pitfalls presented. Except numbers 2s good refactor. I hope I won't sound too harsh/picky for an example that perhaps skipped renaming for clarity on the other parts, but I wanted to mention it.

    While I don't use javascript and may be missing some of the norms and context of the lanugage, creating lamda functions (i don't know the js term) and then hardcoding them into a function is barely an improvement. It's fine because they work well with map and filter, but it didn't address the vague naming. Renaming is refactoring too!

    isAdult is a simple function with a clear name, but formatUser and processUsers are surprisingly vague. formatUser gives only adult FormattedUsers, and that should probably be highlighted in the name of formatUser now that it is a resuable function. To me, it seems ripe for mistaken use given that it is the filter that at a glance handles removing non-adult users before the formatting, while formatUser doesn't appear to exepct only adult users from it's naming or even use! Ideally, formatUser should have checked the age on it's own and set isAdult true/false accordingly, instead of assuming it will be used only on adult Users.

    Likewise, the main function is called processUsers but could easily have been something more descriptive like GetAdultFormattedUsers or something similar depending on naming standards in js and the context it is used in. It may make more sense in the actual context, but in the example a FormattedUser doesn't have to be an adult, so a function processing users should clarify that it only actually creates adult formatted users since there is a case where a FormattedUser is not an adult.

    22
  • Looking for a system/application language that is better than C/C++
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    1mo ago 100%

    He may have used the wrong word, but maintaining the same function signature across two files (while made easier by IDE tools) sucks ass to do. It was one of the major pain points for me doing a C++ course (along with the abyssmal compilation error messages). Not that I have tried Zig, but I do not see a reason to involve header files in my life if I can avoid it.

    2
  • Natural Inspiration
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    2mo ago 100%

    Looks very Norwegian, and there seems to be a crossing on the road used to prevent sheep from leaving the area (while cars still can drive over it) which is also something we have in Norway.

    3
  • is your blue my blue ?
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearBE
    BehindTheBarrier
    2mo ago 100%

    I'm red green colorblind but ended up at 177, which is fairly close to the (as I see at least) middle while line dividing green and blue.

    Which is surprising because I bought blue chopsticks in Japan, and my mother say they are mainly green, much to my frustration.

    3
  • "Initials" by "Florian Körner", licensed under "CC0 1.0". / Remix of the original. - Created with dicebear.comInitialsFlorian Körnerhttps://github.com/dicebear/dicebearTA
    Why every laptop should have at least two USB ports of each kind

    Some background, I work full stack while we also man the support email from users. I'm manning the support email this week, but today I was also tech support for a fellow developer. We use HP docks to connect everything from screens to keyboards. But today a dock would not do anything when my colleague attempted to use it. Being the nosy kind, I went and asked the usual - Did you reboot? - Did you remove the power to the dock? - Try messing with the drivers? - lock the screen before unplugging? - Tried another dock? All yes, none worked. Our IT support hadn't opened for the day yet and he was looking into updating the specific dock driver. So I asked, did you try the other USB-C port? And what do you know, that worked. Then he just plugged right back into the first USB-C port and everything was back to normal. I don't know who made the drivers, but it's pretty danning when they can brick a specific USB port until it's forced to redo whatever config that messes it up, by using another USB port... If anyone wonders, the docks have a magnetically joined charging and USB plug, so it's fairly natural to plug them in together side by side. It's also almost uniquely a dock issue and not a dead USB port, so it's funny that the enite thing uncloggs from just using another port for a second. But a reboot does not...

    31
    1

    I'm super new to Rust, like a day old really. But I tried a program made in Rust on Windows, and it refuses to work. Never prints anything. Just straight up instantly dead. Long story short, this thing relies on some linked stuff like ffmpeg in some form. So, I did my best trying to gather all the things it needs per github issues, reddit and other souces. And the end result was that it now spent 0.1 s longer before crashing, actually leaving time for some error in the Windows Event log. Nothing useful there either as far as I can see. So I clone the repo and get the required things to compile Rust, and I managed to build it from source at least. The executable doesn't run, but the Run in VS Code works, somehow. It prints the error messages corresponding to missing input. So i try to debug it, but nothing happens. No breakpoint is hit, and nothing is printed in the terminal, unlike when using Run or cargo Run. I can also just strip out everything it does in the file the main function is in, and it will hit breakpoints. But that didn't help me find out what is missing/broken though. So what the difference, is there a way to catch and prevent Rust from just going silent, and actually tell you what dependencies it failed to load? My entire reason for getting it running locally is to fix that. Because no one sane wants to deal with a program that doesn't tell you why it will not run... And when debugging also does nothing... I'm out of ideas. The program is called Av1an for reference, and it's a video encoding tool. I used a python version before they migrated to Rust, and wanted to give it a try again. Edit: Wrote linked library, but i think the proper term is dynamic libraries. I'm really not good with compiled programs. Update: Figured it out. Had to copy the out files from the ffmpeg compiled stuff back to the executable. Apparently Cargo Run includes that location when looing for the files, while running from the command line clearly doesn't. But the biggest whiplash, was that I got a full windows dialog popup when i tried to in the exectuable in CMD instead of Powershell. Told me the exact file I was missing too. I know PowerShell is a bitch when piping stuff, but I'm amazed no other program or error message could hand me that vital information. Fuck me, I wish I had tried that from the start....

    21
    13