catch invalid argument exception, but alert the developer during debugging

The server could change the type, or provide the wrong type, for a field. This shouldn’t cause the client to crash.