Modernized the error catching syntax
Modernized the error catching syntax


Former-commit-id: d9b1a854ae0fc4ab2a9ee6bbd8e9b3a9b848ffa7 [formerly 02c6eeede444274a66197d227ecb57b304e7fac2]
Former-commit-id: 4e6f9ba02821128ae4deba7b071413647a16ca1e
gem/oq-engine,gem/oq-engine,gem/oq-engine,gem/oq-engine,gem/oq-engine