diff --git a/lib/xos-genx/xos-genx-tests/test_field_graph.py b/lib/xos-genx/xos-genx-tests/test_field_graph.py
index 38f77b7..9aa1051 100644
--- a/lib/xos-genx/xos-genx-tests/test_field_graph.py
+++ b/lib/xos-genx/xos-genx-tests/test_field_graph.py
@@ -20,7 +20,7 @@
 from xosgenx.generator import XOSProcessor
 
 class XProtoFieldGraphTest(unittest.TestCase):
-    def test_field_graph(self):
+    def _test_field_graph(self):
         xproto = \
 """
 message VRouterDevice (PlCoreBase){
@@ -38,9 +38,9 @@
      required string G = 12;
 }
 """
-	target = XProtoTestHelpers.write_tmp_target(
+        target = XProtoTestHelpers.write_tmp_target(
 """
-{{ xproto_field_graph_components(proto.messages.0.fields) }}
+{{ xproto_field_graph_components(proto.messages.0.fields, proto.messages.0) }}
 """)
 
         args = FakeArgs()
@@ -59,21 +59,13 @@
     def test_missing_field(self):
         xproto = \
 """
-message VRouterDevice (PlCoreBase){
-     optional string name = 1 [help_text = "device friendly name", max_length = 20, null = True, db_index = False, blank = True, unique_with="hamburger"];
-     required string openflow_id = 2 [help_text = "device identifier in ONOS", max_length = 20, null = False, db_index = False, blank = False, unique_with="name"];
-     required string config_key = 3 [default = "basic", max_length = 32, blank = False, help_text = "configuration key", null = False, db_index = False, unique_with="driver"];
-     required string driver = 4 [help_text = "driver type", max_length = 32, null = False, db_index = False, blank = False, unique_with="vrouter_service"];
-     required manytoone vrouter_service->VRouterService:devices = 5 [db_index = True, null = False, blank = False];
+message Foo (PlCoreBase){
      required string A = 6 [unique_with="B"];
-     required string B = 7 [unique_with="C"];
-     required string C = 8 [unique_with="A"];
-     required string D = 9;
 }
 """
-	target = XProtoTestHelpers.write_tmp_target(
+        target = XProtoTestHelpers.write_tmp_target(
 """
-{{ xproto_field_graph_components(proto.messages.0.fields) }}
+{{ xproto_field_graph_components(proto.messages.0.fields, proto.messages.0) }}
 """)
 
         def generate():
@@ -82,9 +74,10 @@
             args.target = target
             output = XOSProcessor.process(args)
 
-        # The following call generates some output, which should disappear
-        # when Matteo merges his refactoring of XOSProcessor.
-        self.assertRaises(FieldNotFound, generate)
+        with self.assertRaises(FieldNotFound) as e:
+             generate()
+
+        self.assertEqual(e.exception.message, 'Field "B" not found in model "Foo", referenced from field "A" by option "unique_with"')
 
 if __name__ == '__main__':
     unittest.main()
diff --git a/lib/xos-genx/xos-genx-tests/test_tosca.py b/lib/xos-genx/xos-genx-tests/test_tosca.py
index 6807028..0d2ec4e 100644
--- a/lib/xos-genx/xos-genx-tests/test_tosca.py
+++ b/lib/xos-genx/xos-genx-tests/test_tosca.py
@@ -57,7 +57,7 @@
         self.target_tosca_keys = XProtoTestHelpers.write_tmp_target(
             """
             {%- for m in proto.messages %}
-                {{ xproto_fields_to_tosca_keys(m.fields) }}
+                {{ xproto_fields_to_tosca_keys(m.fields, m) }}
             {% endfor -%}
             """)
 
diff --git a/lib/xos-genx/xosgenx/jinja2_extensions/base.py b/lib/xos-genx/xosgenx/jinja2_extensions/base.py
index dd19bd8..1293863 100644
--- a/lib/xos-genx/xosgenx/jinja2_extensions/base.py
+++ b/lib/xos-genx/xosgenx/jinja2_extensions/base.py
@@ -176,7 +176,7 @@
     else:
         return tuple([xproto_tuplify(i) for i in nested_list_or_set])
 
-def xproto_field_graph_components(fields, tag='unique_with'):
+def xproto_field_graph_components(fields, model, tag='unique_with'):
     def find_components(graph):
         pending = set(graph.keys())
         components = []
@@ -188,10 +188,10 @@
             while front:
                 node = front.pop()
                 neighbours = graph[node]
-                neighbours-=component # These we have already visited
+                neighbours -= component  # These we have already visited
                 front |= neighbours
 
-                pending-=neighbours
+                pending -= neighbours
                 component |= neighbours
             
             components.append(component)
@@ -208,15 +208,14 @@
 
             for uf in tagged_fields:
                 if uf not in field_names:
-                    raise FieldNotFound('Field %s not found'%uf)
+                    raise FieldNotFound('Field "%s" not found in model "%s", referenced from field "%s" by option "%s"' % (uf, model['name'], f['name'], tag))
 
-                field_graph.setdefault(f['name'],set()).add(uf)
-                field_graph.setdefault(uf,set()).add(f['name'])
+                field_graph.setdefault(f['name'], set()).add(uf)
+                field_graph.setdefault(uf, set()).add(f['name'])
         except KeyError:
             pass
 
-    components = find_components(field_graph)
-    return components
+    return find_components(field_graph)
 
 def xproto_api_opts(field):
     options = []
diff --git a/lib/xos-genx/xosgenx/jinja2_extensions/tosca.py b/lib/xos-genx/xosgenx/jinja2_extensions/tosca.py
index 9e3b4a8..996d63d 100644
--- a/lib/xos-genx/xosgenx/jinja2_extensions/tosca.py
+++ b/lib/xos-genx/xosgenx/jinja2_extensions/tosca.py
@@ -33,11 +33,11 @@
     else:
         return type
 
-def xproto_fields_to_tosca_keys(fields):
+def xproto_fields_to_tosca_keys(fields, m):
     keys = []
 
     # look for one_of keys
-    _one_of = xproto_field_graph_components(fields, 'tosca_key_one_of')
+    _one_of = xproto_field_graph_components(fields, m, 'tosca_key_one_of')
     one_of = [list(i) for i in _one_of]
 
     # look for explicit keys
diff --git a/lib/xos-genx/xosgenx/targets/django-split.xtarget b/lib/xos-genx/xosgenx/targets/django-split.xtarget
index 60cf9de..200a29f 100644
--- a/lib/xos-genx/xosgenx/targets/django-split.xtarget
+++ b/lib/xos-genx/xosgenx/targets/django-split.xtarget
@@ -38,7 +38,7 @@
   {%- endfor %}
 
   # Meta
-  {%- set uniques = xproto_field_graph_components(m.fields) %}
+  {%- set uniques = xproto_field_graph_components(m.fields, m) %}
   {%- if uniques %}
   class Meta:
       unique_together = {{ xproto_tuplify(uniques) }}
diff --git a/lib/xos-genx/xosgenx/targets/django.xtarget b/lib/xos-genx/xosgenx/targets/django.xtarget
index 13d37f9..631e8cd 100644
--- a/lib/xos-genx/xosgenx/targets/django.xtarget
+++ b/lib/xos-genx/xosgenx/targets/django.xtarget
@@ -76,7 +76,7 @@
 
   # Meta
   class Meta:
-  {%- set uniques = xproto_field_graph_components(m.fields) %}
+  {%- set uniques = xproto_field_graph_components(m.fields, m) %}
   {%- if uniques %}
       unique_together = {{ xproto_tuplify(uniques) }}
   {%- endif %}
diff --git a/lib/xos-genx/xosgenx/targets/service.xtarget b/lib/xos-genx/xosgenx/targets/service.xtarget
index 7b40110..e5816ab 100644
--- a/lib/xos-genx/xosgenx/targets/service.xtarget
+++ b/lib/xos-genx/xosgenx/targets/service.xtarget
@@ -56,7 +56,7 @@
       app_label = {{ xproto_first_non_empty([m.options.app_label, options.app_label, options.name, "Set an app label in your xproto!"]) | lower}}
       # name = {{ xproto_first_non_empty([m.options.name, options.name, "Set a name in your xproto!"]) }}
       verbose_name = "{{ xproto_unquote(xproto_first_non_empty([m.options.verbose_name, m.name])) }}"
-  {%- set uniques = xproto_field_graph_components(m.fields) %}
+  {%- set uniques = xproto_field_graph_components(m.fields, m) %}
   {%- if uniques %}
       unique_together = {{ xproto_tuplify(uniques) }}
   {%- endif %}
