I would say the productivity comes from the established community around Ruby, when it comes to web development.
It's true that you end up running into certain types of bugs that a strongly typed language would've caught immediately, but in java/c#/rust you end up having to hand implement more stuff depending on what you're doing.
Ideally I would use rust, but I also think Ruby can work quite well if defensive programming practices are followed, as well as running linters, static analyzers, etc. Most issues seem to stem from poor architecture or tightly coupled, dense code.