File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -353,13 +353,14 @@ def _fill_and_validate_mirrors(self):
353353 linked_entity = attr_spec .relation_to
354354 linked_attr = attr_spec .mirror_as
355355
356- mirror_attr = AttrSpecReadOnly (
357- id = linked_attr ,
358- name = linked_attr ,
359- data_type = f"set<link<{ entity } >>" ,
360- type = "plain" ,
361- description = f"Read-only mirror attribute of { entity } .{ attr } " ,
362- )
356+ with entity_context (self .entities [entity ], self .entities ):
357+ mirror_attr = AttrSpecReadOnly (
358+ id = linked_attr ,
359+ name = linked_attr ,
360+ data_type = f"set<link<{ entity } >>" ,
361+ type = "plain" ,
362+ description = f"Read-only mirror attribute of { entity } .{ attr } " ,
363+ )
363364
364365 # We will accept correct definitions of mirrored attributes to fix errors when
365366 # a `ModelSpec` instance is validated again (e.g. when passed to `PlatformConfig`)
You can’t perform that action at this time.
0 commit comments