saygoodbyye opened a new issue, #1305:
URL: https://github.com/apache/age/issues/1305

   **Describe the bug**
   Server crashes when executing the following SQL-script
   
   **How are you accessing AGE (Command line, driver, etc.)?**
   Accessing AGE through command line.
   
   **What data setup do we need to do?**
   Apache AGE (PG15 branch) with PostgreSQL (REL_15_STABLE).
   
   **What is the necessary configuration info needed?**
   My PostgreSQL configuration:
   ```
   ./configure CFLAGS=" -Og" --enable-tap-tests --enable-debug --enable-cassert
   ```
   
   **What is the command that caused the error?**
   ```pgsql
   CREATE EXTENSION age;
   SET search_path TO ag_catalog;
   DROP EXTENSION age;
   CREATE EXTENSION age;
   SELECT create_graph('drop');
   SELECT create_graph('graph');
   SELECT create_vlabel('graph', 'n');
   SELECT create_elabel('graph', 'r');
   SELECT drop_label('graph', 'r', false);
   SELECT drop_label('graph', 'r');
   ```
   backtrace:
   ```
   #0  __strlen_avx2 () at ../sysdeps/x86_64/multiarch/strlen-avx2.S:76
   #1  0x000056006610a878 in namehashfast (datum=0) at catcache.c:144
   #2  0x000056006610a551 in CatalogCacheComputeHashValue 
(cache=cache@entry=0x560067e1c980, nkeys=nkeys@entry=2, v1=v1@entry=0, 
v2=v2@entry=17573, v3=v3@entry=0, v4=v4@entry=0)
       at catcache.c:297
   #3  0x000056006610b2e9 in SearchCatCacheInternal (cache=0x560067e1c980, 
nkeys=2, v1=0, v2=17573, v3=v3@entry=0, v4=v4@entry=0) at catcache.c:1233
   #4  0x000056006610b823 in SearchCatCache (cache=<optimized out>, 
v1=<optimized out>, v2=<optimized out>, v3=v3@entry=0, v4=v4@entry=0) at 
catcache.c:1150
   #5  0x000056006611ee1b in SearchSysCache (cacheId=cacheId@entry=54, 
key1=<optimized out>, key2=<optimized out>, key3=key3@entry=0, 
key4=key4@entry=0) at syscache.c:1169
   #6  0x000056006611f09f in GetSysCacheOid (cacheId=cacheId@entry=54, 
oidcol=oidcol@entry=1, key1=<optimized out>, key2=<optimized out>, 
key3=key3@entry=0, key4=key4@entry=0)
       at syscache.c:1293
   #7  0x000056006610f702 in get_relname_relid (relname=<optimized out>, 
relnamespace=<optimized out>) at lsyscache.c:1868
   #8  0x0000560065d35c29 in RangeVarGetRelidExtended 
(relation=relation@entry=0x560067fa0c78, lockmode=lockmode@entry=8, 
flags=flags@entry=1, 
       callback=callback@entry=0x7f17b8efdeb0 
<range_var_callback_for_remove_relation>, callback_arg=callback_arg@entry=0x0) 
at namespace.c:331
   #9  0x00007f17b8efdde2 in remove_relation (qname=<optimized out>) at 
src/backend/commands/label_commands.c:801
   #10 0x00007f17b8efe615 in drop_label (fcinfo=<optimized out>) at 
src/backend/commands/label_commands.c:774
   #11 0x0000560065e481e2 in ExecInterpExpr (state=0x560067f37d00, 
econtext=0x560067f37a00, isnull=0x7ffda865e577) at execExprInterp.c:727
   #12 0x0000560065e44f78 in ExecInterpExprStillValid (state=0x560067f37d00, 
econtext=0x560067f37a00, isNull=0x7ffda865e577) at execExprInterp.c:1826
   #13 0x0000560065e837fd in ExecEvalExprSwitchContext (state=<optimized out>, 
econtext=<optimized out>, isNull=<optimized out>) at 
../../../src/include/executor/executor.h:344
   #14 0x0000560065e83844 in ExecProject (projInfo=0x560067f37cf8) at 
../../../src/include/executor/executor.h:378
   #15 0x0000560065e839fd in ExecResult (pstate=<optimized out>) at 
nodeResult.c:136
   #16 0x0000560065e54971 in ExecProcNodeFirst (node=0x560067f378e8) at 
execProcnode.c:464
   #17 0x0000560065e4c71a in ExecProcNode (node=node@entry=0x560067f378e8) at 
../../../src/include/executor/executor.h:262
   #18 0x0000560065e4c7aa in ExecutePlan (estate=estate@entry=0x560067f376b0, 
planstate=0x560067f378e8, use_parallel_mode=<optimized out>, 
operation=operation@entry=CMD_SELECT, 
       sendTuples=sendTuples@entry=true, numberTuples=numberTuples@entry=0, 
direction=ForwardScanDirection, dest=0x560067e86908, execute_once=true) at 
execMain.c:1636
   #19 0x0000560065e4d569 in standard_ExecutorRun (queryDesc=0x560067fac300, 
direction=ForwardScanDirection, count=0, execute_once=true) at execMain.c:363
   #20 0x0000560065e4d699 in ExecutorRun 
(queryDesc=queryDesc@entry=0x560067fac300, 
direction=direction@entry=ForwardScanDirection, count=count@entry=0, 
execute_once=<optimized out>)
       at execMain.c:307
   #21 0x0000560065ff4fdf in PortalRunSelect 
(portal=portal@entry=0x560067e279d0, forward=forward@entry=true, count=0, 
count@entry=9223372036854775807, dest=dest@entry=0x560067e86908)
       at pquery.c:924
   #22 0x0000560065ff6861 in PortalRun (portal=portal@entry=0x560067e279d0, 
count=count@entry=9223372036854775807, isTopLevel=isTopLevel@entry=true, 
run_once=run_once@entry=true, 
       dest=dest@entry=0x560067e86908, altdest=altdest@entry=0x560067e86908, 
qc=0x7ffda865e8a0) at pquery.c:768
   #23 0x0000560065ff29ed in exec_simple_query 
(query_string=query_string@entry=0x560067db9f40 "SELECT drop_label('graph', 
'r');") at postgres.c:1250
   #24 0x0000560065ff4851 in PostgresMain (dbname=<optimized out>, 
username=<optimized out>) at postgres.c:4598
   #25 0x0000560065f59832 in BackendRun (port=port@entry=0x560067ddaf70) at 
postmaster.c:4514
   #26 0x0000560065f5b842 in BackendStartup (port=port@entry=0x560067ddaf70) at 
postmaster.c:4242
   #27 0x0000560065f5ba7b in ServerLoop () at postmaster.c:1809
   #28 0x0000560065f5d050 in PostmasterMain (argc=argc@entry=3, 
argv=argv@entry=0x560067db44b0) at postmaster.c:1481
   #29 0x0000560065ea9db8 in main (argc=3, argv=0x560067db44b0) at main.c:202
   ```
   
   **Expected behavior**
   Expected ERROR to be shown or sql query to be succesfully executed
   
   Also reproduces on AGE master branch


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@age.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to