The double quotes around the regular expression are mandatory and they are not part of the regular expression itself.
Broken connections can only be detected if something is expected (see Connection error handling).