As part of crrev.com/c/784372 I got an invalid message error when trying to serialize/deserialize an enum (see below).
I only had 2 enums that could be at fault, so wasn't hard to figure out, however the error message should try to help by saying (if possible):
- What enum or message was invalid.
- What was the invalid value.
For the record, the error was due to a bitfield enum missing "Extensible]" on mojo module.
Error message:
Note: Google Test filter = SitePerProcessBrowserTest.ActiveSandboxFlagsCorrectWhenCleared
[==========] Running 1 test from 1 test case.
[----------] Global test environment set-up.
[----------] 1 test from SitePerProcessBrowserTest, where TypeParam =
[ RUN ] SitePerProcessBrowserTest.ActiveSandboxFlagsCorrectWhenCleared
DevTools listening on ws://127.0.0.1:34405/devtools/browser/b7e20ed9-8fd9-4479-890e-8a6f0a2c12f4
[35911:35935:1207/132402.575010:ERROR:instance.cc(49)] Unable to locate service manifest for metrics
[35911:35935:1207/132402.575132:ERROR:service_manager.cc(890)] Failed to resolve service name: metrics
[35939:35939:1207/132403.005453:WARNING:gpu_info.cc(103)] No active GPU found, returning primary GPU.
[35911:35935:1207/132403.178776:ERROR:instance.cc(49)] Unable to locate service manifest for metrics
[35911:35935:1207/132403.178881:ERROR:service_manager.cc(890)] Failed to resolve service name: metrics
[35911:35911:1207/132403.442489:ERROR:validation_errors.cc(87)] Invalid message: VALIDATION_ERROR_UNKNOWN_ENUM_VALUE
[35911:35911:1207/132403.442590:ERROR:render_process_host_impl.cc(4143)] Terminating render process for bad Mojo message: Received bad user
message: Validation failed for FrameHost RequestValidator [VALIDATION_ERROR_UNKNOWN_ENUM_VALUE]
[35911:35911:1207/132403.442636:ERROR:bad_message.cc(23)] Terminating renderer for bad IPC message, reason 123
[35911:35911:1207/132403.442822:ERROR:validation_errors.cc(87)] Invalid message: VALIDATION_ERROR_UNKNOWN_ENUM_VALUE
[35911:35911:1207/132403.442890:ERROR:render_process_host_impl.cc(4143)] Terminating render process for bad Mojo message: Received bad user
message: Validation failed for FrameHost RequestValidator [VALIDATION_ERROR_UNKNOWN_ENUM_VALUE]
[35911:35911:1207/132403.442935:ERROR:bad_message.cc(23)] Terminating renderer for bad IPC message, reason 123
[35911:35911:1207/132403.462030:FATAL:web_contents_observer_sanity_checker.cc(303)] Check failed: is_loading_.
#0 0x7facf052bdad base::debug::StackTrace::StackTrace()
#1 0x7facf052a1dc base::debug::StackTrace::StackTrace()
.....
Suggested error msg:
[35911:35911:1207/132403.442489:ERROR:validation_errors.cc(87)] Invalid message: VALIDATION_ERROR_UNKNOWN_ENUM_VALUE for EnumTypeNameHere value "XXX".
Comment 1 by oksamyt@chromium.org
, Jan 15