You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, recently I updated the xo version and found out that xo is generating thousands of postgresql enum golang structs for one postgresql enum.
After a little investigation I figured that after PR #337 this issue appeared. The root cause might be releted to this postgresql query
in models/enum.xo.go (line 18-23):
SELECT
c.relname AS table_name, t.typname
FROM pg_class c, pg_type t
JOIN ONLY pg_namespace n ON n.oid = t.typnamespace
JOIN ONLY pg_enum e ON t.oid = e.enumtypid
WHERE n.nspname = $1
The pg_class table is added in the query without any join criteria or where criteria, thus it is generating tons of results for one enum type.
The text was updated successfully, but these errors were encountered:
Hi, recently I updated the xo version and found out that xo is generating thousands of postgresql enum golang structs for one postgresql enum.
After a little investigation I figured that after PR #337 this issue appeared. The root cause might be releted to this postgresql query
in models/enum.xo.go (line 18-23):
The
pg_class
table is added in the query without any join criteria or where criteria, thus it is generating tons of results for one enum type.The text was updated successfully, but these errors were encountered: