graphile / crystal

🔮 Graphile's Crystal Monorepo; home to Grafast, PostGraphile, pg-introspection, pg-sql2 and much more!
https://graphile.org/
Other
12.61k stars 570 forks source link

Rename of functions with same name but different signatures #2171

Open clrgit opened 1 month ago

clrgit commented 1 month ago

Summary

The @name smarttag doesn't seems to work when renaming functions with the same name but different signatures

Version 4.12.11

Steps to reproduce

The following code demonstrates the problem:

drop function if exists func(integer);
drop function if exists func(integer, integer);

create function func(i integer) returns integer as $$
  select i
$$ language sql;

create function func(i integer, j integer) returns integer as $$
  select i + j
$$ language sql;

comment on function func(integer) is E'@name func1';
comment on function func(integer, integer) is E'@name func2';

Expected results

When creating a new mutation, I would expect the renamed functions 'func1' and 'func2' to show up in GraphiQL

Actual results

Neither the renamed functions nor the original functions are available in GraphiQL

benjie commented 1 month ago

This seems to be an issue in V5 also.