added exception handling for json version