With mastering I meant being able to perfectly play the game, not only understanding all of its mechanics.
There's really no point in playing a game that might be impossible to win to begin with because of bad luck. Whether bad luck creates too strong monsters or bad luck doesn't connect a floor at all doesn't really matter, it's impossible either way.
I think maybe we are talking about two different things in discussing luck. I see risk as luck. To me a roguelike intentionally hides information from the player through item identification and FoV, adds a dice roll to combat, and randomly generates gear/enemies to create risk.
Now if luck means there is a 50/50 chance the game will give you enough resources to win or that the levels will be connected or the enemies you are faced with are beatable, then yes this is poor design. However, risk is created by providing situations where success cannot be determined given the knowledge provided to a player.
For example, say you enter combat with an enemy and another joins the fray from outside your FoV. A smart player may weigh his odds and determine fleeing is the best option. He might use a teleport scroll and randomly find himself in another area. This isn't without risk however, as he might find himself in a worse situation and die.
If you always have perfect knowledge of the game and the outcome of each action, such as in chess, than yes a good player should always win. However, I think withholding the game state leads to more interesting play, say as in poker.
You have no way of knowing if the next blow will hit, you only know the odds. You don't know if retreating into the next room will leave you in a worse situation or not, only the odds. You have no idea whether that un-id potion will benefit you or hurt you, only the odds.
As the game progresses and the player accumulates resources and develops their character, they should have more control over the game and find themselves less forced to play the odds.
But ideally there cannot be perfect play, as perfect play requires perfect knowledge of the game state. To achieve perfect play you'd need to know the state of the RNG. If you could achieve perfect play then winning should be 100% assured. Perfect play would require counting the cards, barring that you are left playing the hand you are dealt.