#8821·gel

Migration cannot be created: InvalidReferenceError: property 'id' does not exist

Author: CarsonFCreated Jun 20, 2025Updated Mar 3, 2026
Labelsbugcompiler
  • Gel Version: 6.8
  • Gel CLI Version: 7.4.0+bb0c441
  • OS Version:

Schema:

edgeql
module default {
  global currentActorId: uuid;
  global currentActor := (select Actor filter .id = global currentActorId);
  global currentRoles := (global currentActor).roles;

  scalar type Role extending enum<
    Administrator,
    Leadership,
    StaffMember,
  >;

  abstract type Resource {
    access policy CanSelectUpdateReadGeneratedFromAppPoliciesForResource
    allow select, update read using (
      exists (<Role>{'Administrator', 'Leadership'} intersect global currentRoles)
    );
  };

  type Actor {
    required name: str { constraint exclusive };
    multi roles: Role;
  }
  type User extending Resource, Actor {
    email: str {
      constraint exclusive;
    };
  }
  type SystemAgent extending Actor;
}

module Mixin {
  abstract type Postable extending default::Resource;
}

Trying to create first migration from that renders:

gel error: InvalidReferenceError: property 'id' does not exist