Fix: config: packet context type is mandatory and must be a struct
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Wed, 16 Mar 2016 00:29:03 +0000 (20:29 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Fri, 18 Mar 2016 21:54:59 +0000 (17:54 -0400)
Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
barectf/config.py

index 078ae3c58f8467e59c4c2f54ce309087b30fe93a..bc0e4cfc81ec237100fc66dd3136efb38b4e30bb 100644 (file)
@@ -394,10 +394,10 @@ class _MetadataSpecialFieldsValidator:
         t = stream.packet_context_type
 
         if type(t) is None:
-            return
+            raise ConfigError('missing "packet-context-type" property in stream object')
 
         if type(t) is not metadata.Struct:
-            return
+            raise ConfigError('"packet-context-type": expecting a structure type')
 
         # "timestamp_begin", if exists, is an unsigned integer type,
         # mapped to a clock
This page took 0.026422 seconds and 4 git commands to generate.