Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migration Create -> InternalServerError: AssertionError: (due to invalid overloaded pointer) #7318

Open
CarsonF opened this issue May 8, 2024 · 1 comment

Comments

@CarsonF
Copy link

CarsonF commented May 8, 2024

  • EdgeDB Version: 5.1+4ced01b
  • EdgeDB CLI Version: 5.2.0-dev.1153+93311cf
  • OS Version: mac

Steps to Reproduce:

  1. migration create
edgedb error: InternalServerError: AssertionError: 
Server traceback:
  Traceback (most recent call last):
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/server/compiler_pool/worker.py", line 178, in compile
      units, cstate = COMPILER.compile_request(
                      ^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/server/compiler/compiler.py", line 857, in compile_request
      units, cstate = self.compile(
                      ^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/server/compiler/compiler.py", line 937, in compile
      unit_group = compile(ctx=ctx, source=source)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/server/compiler/compiler.py", line 2585, in compile
      return _try_compile(ctx=ctx, source=source)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/server/compiler/compiler.py", line 2663, in _try_compile
      comp, capabilities = _compile_dispatch_ql(
                           ^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/server/compiler/compiler.py", line 2490, in _compile_dispatch_ql
      query = ddl.compile_dispatch_ql_migration(
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/server/compiler/ddl.py", line 386, in compile_dispatch_ql_migration
      return _start_migration(ctx, ql, in_script)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/server/compiler/ddl.py", line 466, in _start_migration
      target_schema = s_ddl.apply_sdl(
                      ^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/ddl.py", line 595, in apply_sdl
      process(ddl_stmt)
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/ddl.py", line 537, in process
      cmd = cmd_from_ddl(
            ^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/ddl.py", line 467, in cmd_from_ddl
      res = sd.compile_ddl(schema, ddl, context=context)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/delta.py", line 4457, in compile_ddl
      cmd = cmdcls._cmd_tree_from_ast(schema, astnode, context)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/inheriting.py", line 1061, in _cmd_tree_from_ast
      cmd = super()._cmd_tree_from_ast(schema, astnode, context)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/delta.py", line 3583, in _cmd_tree_from_ast
      cmd = super()._cmd_tree_from_ast(schema, astnode, context)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/delta.py", line 1110, in _cmd_tree_from_ast
      subcmd = compile_ddl(schema, subastnode, context=context)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/delta.py", line 4457, in compile_ddl
      cmd = cmdcls._cmd_tree_from_ast(schema, astnode, context)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/unknown_pointers.py", line 94, in _cmd_tree_from_ast
      cmd._process_create_or_alter_ast(schema, fakenode, context)
    File "edgedb/portable/5.1/lib/python3.12/site-packages/edb/schema/pointers.py", line 1989, in _process_create_or_alter_ast
      assert astnode.target is not None
  AssertionError

Schema:
SeedCompany/cord-api-v3@8b7354c

@CarsonF
Copy link
Author

CarsonF commented May 10, 2024

Ok this is actually because I have overloaded owner which is a link that is no longer an inherited link. It was removed, and then this branch was rebased.

So just a nicer error message would help with this user error.

@CarsonF CarsonF changed the title Migration Create -> InternalServerError: AssertionError: Migration Create -> InternalServerError: AssertionError: (due to invalid overloaded pointer) May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant