simplify
add RPC handler, fix browser-side RPC error handling
cleanup