Most modern video games have pretty complex rules, and very few of them explain them all up-front. Sometimes this is even deliberate; designers or fans raise an argument like "Exploring and figuring the rules out for yourself is part of the game". This defense is frankly asinine.

If I don't know the rules of a game, then it's not a legitimate challenge. If I don't know how much damage the fireball spell does before I invest in it, I cannot make a meaningful decision. I'm just guessing what the designer would've done. That's not challenging gameplay. It's trial and error.

Of course, that's a lot less bad if the game allows you to re-spec or sell an item for the same price, but even then, just why? There's no reason I should have to buy it and go die with it to find out it's not worth buying. Just give me the information up-front so I can make a meaningful decision.

Another frequent cause of trial and error in action games is requiring you to read an enemy's physical sprite movements to know what attack is coming in time to dodge it. The problem with this is that video game worlds aren't bound by real-life physics, so it's often not possible for even the most attentive and smartest player to correctly infer how they should dodge an attack they haven't seen before. The safest way to avoid this is clearly teaching the player what means what (or at least allowing them to practice it in a situation where there are no consequences for failure), although Mario and Luigi: Bowser's Inside Story and Jedi: Fallen Order demonstrate that it's possible to do the telegraphs in such a way that the player can reasonably intuit them.

A common reason players don't object to trial and error in games is because they don't realize it's trial and error. They haven't really put their finger on the concept, and so they often assume their death is their fault without even asking whether they had a legitimate way to see it coming. I even did this to myself when I played Dark Souls 1. There were a lot of times I was killed during combat by an attack I couldn't have known how to dodge, but I thought to myself, "Well, there was a telegraph and it was possible to avoid it, so it must have been fair". I denied my feelings because I didn't see how it was possible for that to still be trial and error.