sorted by: new top controversial old
[-] baseless_discourse@mander.xyz 18 points 2 days ago* (last edited 1 day ago)

The more I read about these kind of article the more I am amazed that our digital future is at hand in utterly incompetent people.

This person clearly have no understanding of monadic error (AKA Maybe/option monad or slightly more advanced Either monad), which is the first monad we teach at a class targeting second year undergrad.

The performance comparison is just plain factual error. The functional error code will continue to compute n2 when computation of n1 failed; the same do not happen in the exception version. If you compare codes with completely different traces, of course they will have different performance...

A properly implemented monadic error will return as soon as compute for n1 failed, and never execute the rest of the code. This is the default and idiomatic behavior in Haskell, OCaml, F#, and rust. This performance problem doesn't even happen in LINQ-style handling like in C# and Kotlin (maybe also Typescript?).

The point of monadic error is that its control flow is local, whereas exception is non-local. Specifically, the exception can be handled and occur anywhere in the code base, with no indication on the type level. So programmers will be constantly worrying about whether the exception in a function call is properly handled.

Even worse, when you try to catch a certain error, there is always the risk to accidentally catch similar exceptions in a library call or someone else's code. Writing good code with try-catch requires a lot of principle and style guides. But unlike monads, these principle and rules cannot be enforced by the type system, adding extra burden to programmers.

In fact, we have known for a long time that non-local control flows (goto, break, contiune, exception, long jump) are the breeding ground for spaghetti code. As an evidence, many non-local control flows (goto, long jump) are baned in most languages.

That being said, there are certainly cases, with proper documentation, that exception style is easy to write and understand. But I think they are very specific scenarios, which have to be justified on a case-by-case basis.

[-] baseless_discourse@mander.xyz 2 points 3 days ago* (last edited 2 days ago)

Many people don't know usb-c cable is universal, and apple only advertises chargeing iphone with macbook and ipad charger.

I imagine most of these people use an iPhone, and they will certainly waste their money on an "Apple cable".

Plus many of these tech-illiterate people are likely on a lighting iPhone with a barrel jack Windows, they won't even know they need a new charging cable until they realize their old lighting cables don't work.

[-] baseless_discourse@mander.xyz 9 points 3 days ago* (last edited 3 days ago)

Probably runs at usb2 speed and charges at 5w.

[-] baseless_discourse@mander.xyz 3 points 3 days ago* (last edited 3 days ago)

There are support table on asahi wiki. For example, here is the support page of M2: https://github.com/AsahiLinux/docs/wiki/M2-Series-Feature-Support

It is missing thunderbolt, touch id, video decoder, video encoder, DP alt mode, pro res, PCIE etc.

[-] baseless_discourse@mander.xyz 17 points 5 days ago

The cat is playing poker with two mice in the last panel.

[-] baseless_discourse@mander.xyz 1 points 6 days ago

I cannot find anything related to "the promised 10 years of lightening". Do you min providing a source?

[-] baseless_discourse@mander.xyz 4 points 6 days ago

That didn't pass as far as I am aware.

[-] baseless_discourse@mander.xyz 4 points 6 days ago

I was talking about usb-c, and I don't care about RCS, but it is still better in everyway than SMS.

[-] baseless_discourse@mander.xyz 18 points 6 days ago

Forced by EU! Thanks again, EU.

[-] baseless_discourse@mander.xyz 2 points 6 days ago

I want to say "live to see another day", but on retrospect, that is indeed, quite boring.

[-] baseless_discourse@mander.xyz 5 points 1 week ago* (last edited 1 week ago)

Then if you care about the artists being compensated fairly, you can CD+rip; if not, streamrip/torrent will produce a lot less waste and much more convenient.

TBH most big names are millionaires anyway, I probably would care much more about my convenience than them getting paid 5 bucks for all my troubles.

[-] baseless_discourse@mander.xyz 1 points 1 week ago* (last edited 1 week ago)

If you can download music, you can either host your own using navidrome, or just use a local player like auxio.

The only downside to this approach is that the artists you like might not get compensated fairly, as most streaming service pay by stream times. This is also why I prefer buying music than streaming.

8
submitted 1 month ago* (last edited 1 month ago) by baseless_discourse@mander.xyz to c/homeassistant@lemmy.world

cross-posted from: https://mander.xyz/post/16531247

I have tried to follow several tutorial to setup using either ip or nmtui:

However, the bridge inherits the MAC address of host after enslaving the host hardware enp1s0.... This causes my router to give both the host and the bridge the same ip address, making the ha instance inaccessible.

The red hat tutorial clearly show that the bridge and the host have different IP, so I was wondering if I am doing something wrong.


alternatively, I can set the home assistant vm to run in NAT and port forward from host, but I have several device that communicate over different ports. So it would be annoying to forward all these ports. Not to mention, many appliances don't have documentation about the ports they use.

I can also potentially use virtualbox, but it is not well supported on silverblue, especially with secureboot enabled.

19
submitted 1 month ago* (last edited 1 month ago) by baseless_discourse@mander.xyz to c/linux@lemmy.ml

I have tried to follow several tutorial to setup using either ip or nmtui:

However, the bridge inherits the MAC address of host after enslaving the host hardware enp1s0.... This causes my router to give both the host and the bridge the same ip address, making the ha instance inaccessible.

The red hat tutorial clearly show that the bridge and the host have different IP, so I was wondering if I am doing something wrong.


alternatively, I can set the home assistant vm to run in NAT and port forward from host, but I have several devices that communicate over different ports. So it would be annoying to forward all these ports. Not to mention, many appliances don't have documentation about the ports they use.

I can also potentially use virtualbox, but it is not well supported on silverblue, especially with secureboot enabled.

0
submitted 8 months ago* (last edited 8 months ago) by baseless_discourse@mander.xyz to c/technology@lemmy.ml
33
submitted 8 months ago* (last edited 8 months ago) by baseless_discourse@mander.xyz to c/technology@lemmy.world
63
submitted 8 months ago* (last edited 8 months ago) by baseless_discourse@mander.xyz to c/technology@beehaw.org
27
submitted 10 months ago* (last edited 10 months ago) by baseless_discourse@mander.xyz to c/linux@lemmy.ml

I have setup my fedora to use LUKS encryoted partitions. But entering two passwords gets quite tiring, as I shutdown my laptop quite often to get the benefit of LUKS (I am assuming nothing is encrypted when in suspend, please correctme if I am wrong)

I am thinking about setting up TPM autodecrypt. However, I was wondering does the decryption happen on boot or after I login?

If it happens on boot, then it seems like the benefit is pretty limited compare to a unencrypted drive. Since the attacker can simply boot my laptop and get the unecrypted drive.

Am I missing something here? I was wondering is there a way for me to enter my password once and unlock everything, from disk to gnome keyring?

383
Fairphone 5 Released (shop.fairphone.com)
submitted 1 year ago* (last edited 1 year ago) by baseless_discourse@mander.xyz to c/technology@beehaw.org

With 5 years of OS support and 8 years of security update.

Related threads:

view more: next ›

baseless_discourse

joined 1 year ago