error when state is pending makes reconnect