craftcms / cms

Build bespoke content experiences with Craft.
https://craftcms.com
Other
3.22k stars 627 forks source link

Exception: The table does not exist: {{%fieldgroups}} #10273

Closed Bilge closed 2 years ago

Bilge commented 2 years ago

Description

./craft setup fails on fresh install with:

> saving default site data ... Exception: The table does not exist: {{%fieldgroups}} (vendor\yiisoft\yii2\db\ActiveRecord.php:438)
Which database driver are you using? [mysql,pgsql,?]: pgsql
Database server name or IP address: [127.0.0.1]
Database port: [5432]
Database username: [root] <REDACTED>
Database password: <REDACTED>

Database name: Foo\ Bar
Database schema: [public] craft
Database table prefix:
Testing database credentials ... success!
Saving database credentials to your .env file ... done

Install Craft now? (yes|no) [yes]:

Username: [admin] <REDACTED>
Email: <REDACTED>
Password: <REDACTED>

Confirm: <REDACTED>

Site name: <REDACTED>
Site URL: [https://<REDACTED>.com]
Site language: [en-US] en-GB
*** installing Craft
    > create table {{%announcements}} ... done (time: 0.113s)
    > create table {{%assetindexdata}} ... done (time: 0.067s)
    > create table {{%assets}} ... done (time: 0.024s)
    > create table {{%assettransformindex}} ... done (time: 0.067s)
    > create table {{%assettransforms}} ... done (time: 0.066s)
    > create table {{%categories}} ... done (time: 0.033s)
    > create table {{%categorygroups}} ... done (time: 0.058s)
    > create table {{%categorygroups_sites}} ... done (time: 0.066s)
    > create table {{%changedattributes}} ... done (time: 0.025s)
    > create table {{%changedfields}} ... done (time: 0.033s)
    > create table {{%content}} ... done (time: 0.025s)
    > create table {{%craftidtokens}} ... done (time: 0.058s)
    > create table {{%deprecationerrors}} ... done (time: 0.058s)
    > create table {{%drafts}} ... done (time: 0.058s)
    > create table {{%elementindexsettings}} ... done (time: 0.058s)
    > create table {{%elements}} ... done (time: 0.033s)
    > create table {{%elements_sites}} ... done (time: 0.067s)
    > create table {{%resourcepaths}} ... done (time: 0.075s)
    > create table {{%revisions}} ... done (time: 0.066s)
    > create table {{%sequences}} ... done (time: 0.034s)
    > create table {{%systemmessages}} ... done (time: 0.058s)
    > create table {{%entries}} ... done (time: 0.033s)
    > create table {{%entrytypes}} ... done (time: 0.073s)
    > create table {{%fieldgroups}} ... done (time: 0.034s)
    > create table {{%fieldlayoutfields}} ... done (time: 0.033s)
    > create table {{%fieldlayouts}} ... done (time: 0.034s)
    > create table {{%fieldlayouttabs}} ... done (time: 0.075s)
    > create table {{%fields}} ... done (time: 0.058s)
    > create table {{%globalsets}} ... done (time: 0.066s)
    > create table {{%gqltokens}} ... done (time: 0.075s)
    > create table {{%gqlschemas}} ... done (time: 0.058s)
    > create table {{%info}} ... done (time: 0.041s)
    > create table {{%matrixblocks}} ... done (time: 0.033s)
    > create table {{%matrixblocktypes}} ... done (time: 0.066s)
    > create table {{%migrations}} ... done (time: 0.075s)
    > create table {{%plugins}} ... done (time: 0.058s)
    > create table {{%projectconfig}} ... done (time: 0.050s)
    > create table {{%queue}} ... done (time: 0.091s)
    > create table {{%relations}} ... done (time: 0.033s)
    > create table {{%sections}} ... done (time: 0.066s)
    > create table {{%sections_sites}} ... done (time: 0.066s)
    > create table {{%sessions}} ... done (time: 0.042s)
    > create table {{%shunnedmessages}} ... done (time: 0.033s)
    > create table {{%sites}} ... done (time: 0.058s)
    > create table {{%sitegroups}} ... done (time: 0.034s)
    > create table {{%structureelements}} ... done (time: 0.033s)
    > create table {{%structures}} ... done (time: 0.033s)
    > create table {{%taggroups}} ... done (time: 0.075s)
    > create table {{%tags}} ... done (time: 0.033s)
    > create table {{%templatecacheelements}} ... done (time: 0.042s)
    > create table {{%templatecachequeries}} ... done (time: 0.067s)
    > create table {{%templatecaches}} ... done (time: 0.066s)
    > create table {{%tokens}} ... done (time: 0.058s)
    > create table {{%usergroups}} ... done (time: 0.067s)
    > create table {{%usergroups_users}} ... done (time: 0.033s)
    > create table {{%userpermissions}} ... done (time: 0.042s)
    > create table {{%userpermissions_usergroups}} ... done (time: 0.033s)
    > create table {{%userpermissions_users}} ... done (time: 0.034s)
    > create table {{%userpreferences}} ... done (time: 0.067s)
    > create table {{%users}} ... done (time: 0.083s)
    > create table {{%volumefolders}} ... done (time: 0.067s)
    > create table {{%volumes}} ... done (time: 0.067s)
    > create table {{%widgets}} ... done (time: 0.067s)
    > create index idx_jkowrtsjohudzmzsbtosypecuqrmrzbdyipo on {{%announcements}} (userId,unread,dateRead,dateCreated) ... done (time: 0.033s)
    > create index idx_obezwdldxwyzdrxwcmkjfhhtcxehdusbshft on {{%announcements}} (dateRead) ... done (time: 0.033s)
    > create index idx_ordbecduhcoohzicanowabdtsvmvowzzscmh on {{%assetindexdata}} (sessionId,volumeId) ... done (time: 0.033s)
    > create index idx_pzgebozndiocppgtnqzabprfkxuggoohqkxn on {{%assetindexdata}} (volumeId) ... done (time: 0.033s)
    > create index idx_fhmkyltfmohfcksmxuefequuwlmdnthjlstl on {{%assets}} (filename,folderId) ... done (time: 0.033s)
    > create index idx_mgyunuiqymcsnndacjmjwbipiiwzgglupwsc on {{%assets}} (folderId) ... done (time: 0.033s)
    > create index idx_vkpuxycilspviuqpcqtffpqjmljartvkzeek on {{%assets}} (volumeId) ... done (time: 0.041s)
    > create index idx_boeadahniqhhupcdftkygrmsoltgtbqjbtxr on {{%assettransformindex}} (volumeId,assetId,location) ... done (time: 0.033s)
    > create index idx_wishvfgmwanjcbwiqkfihngcbygpmaeauagr on {{%assettransforms}} (name) ... done (time: 0.033s)
    > create index idx_nvjuejxmuzazkzzfmbthohoqabtnlxmnorjj on {{%assettransforms}} (handle) ... done (time: 0.034s)
    > create index idx_unvepabnuhhpdetkaulowuqjisgbkztyzgim on {{%categories}} (groupId) ... done (time: 0.087s)
    > create index idx_gcybkfwvrlqyywjnqpqblpffgxsfioipacva on {{%categorygroups}} (name) ... done (time: 0.038s)
    > create index idx_txijqobynglbbajnxdwuhhunzqawzqfyinol on {{%categorygroups}} (handle) ... done (time: 0.033s)
    > create index idx_exkajjcyjyxulcejosdczhhyqseivnsbnhdl on {{%categorygroups}} (structureId) ... done (time: 0.033s)
    > create index idx_zfxhokvhqxvrcxskgjjavgohdmrhslzmnzhl on {{%categorygroups}} (fieldLayoutId) ... done (time: 0.033s)
    > create index idx_tigtqakonbtifejuslnzgyjgdnplnjarmqlt on {{%categorygroups}} (dateDeleted) ... done (time: 0.025s)
    > create unique index idx_gvblbpysevmaufneuahxljwqnevdmyhdcwua on {{%categorygroups_sites}} (groupId,siteId) ... done (time: 0.033s)
    > create index idx_xucpezejfdkvasllhoboffzsgrsphmtcocjz on {{%categorygroups_sites}} (siteId) ... done (time: 0.025s)
    > create index idx_aoxoiappcjosiequnuslshkzlwqxcqpbhjvy on {{%changedattributes}} (elementId,siteId,dateUpdated) ... done (time: 0.025s)
    > create index idx_akrpboddkzfdmxhrjamoqquyryvwkryhrkej on {{%changedfields}} (elementId,siteId,dateUpdated) ... done (time: 0.033s)
    > create unique index idx_xivxappqeygzdclcjclyzfknmdtvlmkrkgzr on {{%content}} (elementId,siteId) ... done (time: 0.033s)
    > create index idx_jwnejhdqckrioyqeqdjbtridatubdgdsqabe on {{%content}} (siteId) ... done (time: 0.025s)
    > create index idx_slayvskkaoymenakrvbskornygxwlesfzshi on {{%content}} (title) ... done (time: 0.033s)
    > create unique index idx_ruoxarvwhppealdjvgaamqgggduncryfpcsj on {{%deprecationerrors}} (key,fingerprint) ... done (time: 0.025s)
    > create index idx_wpwyvlpxidntejqbabgagngftzcssvqdevqh on {{%drafts}} (creatorId,provisional) ... done (time: 0.025s)
    > create index idx_qvoippymybfusddvunbtwhmkkvsjdiaegoxy on {{%drafts}} (saved) ... done (time: 0.034s)
    > create unique index idx_popequkbdeolbifsxxqfqmplszfaoxruunmt on {{%elementindexsettings}} (type) ... done (time: 0.041s)
    > create index idx_evaaizhkhundxaknmfawwjbpyswqdomplfpm on {{%elements}} (dateDeleted) ... done (time: 0.033s)
    > create index idx_swziovvepqipkvyhgusssehjswzrvervzejj on {{%elements}} (fieldLayoutId) ... done (time: 0.025s)
    > create index idx_vzppskprsgdupvkhekfagtgatkpwoflhmzia on {{%elements}} (type) ... done (time: 0.025s)
    > create index idx_sflntwtepfjrviswiblmqmddfmxzdrcxtksd on {{%elements}} (enabled) ... done (time: 0.025s)
    > create index idx_mrezilxermuxboherhspawfwyimiqalbbcnw on {{%elements}} (archived,dateCreated) ... done (time: 0.034s)
    > create index idx_xplltwhliwtfsjgjjbpmrkwbgqgnkcvcpesz on {{%elements}} (archived,dateDeleted,draftId,revisionId,canonicalId) ... done (time: 0.033s)
    > create unique index idx_rnnyugaykxxqvtpmbxtqllrsfzzixoypjeeq on {{%elements_sites}} (elementId,siteId) ... done (time: 0.025s)
    > create index idx_bejbbuqpsxttwpmyaxclfebcrazvhdbgkwlk on {{%elements_sites}} (siteId) ... done (time: 0.041s)
    > create index idx_nhuzrbojxeeivzhnvfeuiaetbinufsicmmjp on {{%elements_sites}} (slug,siteId) ... done (time: 0.033s)
    > create index idx_dgztankdqwpvdywmmkzyhxgnctqqdkbcwhvv on {{%elements_sites}} (enabled) ... done (time: 0.033s)
    > create unique index idx_fewccqeakawmzxkuiialkztpshdkgbuxnitj on {{%systemmessages}} (key,language) ... done (time: 0.025s)
    > create index idx_jinpzyqmschlqkohitgziqnkpquhxnzyicpb on {{%systemmessages}} (language) ... done (time: 0.033s)
    > create index idx_tcbhvzyeenukndpucgvcsdpezpubidpwsxuf on {{%entries}} (postDate) ... done (time: 0.034s)
    > create index idx_nnxwgnnvqyjtbczdxnatnhwzpcicadybkmdb on {{%entries}} (expiryDate) ... done (time: 0.041s)
    > create index idx_txwigaomranhvynnetykvrvyqedoyyyyqmoj on {{%entries}} (authorId) ... done (time: 0.025s)
    > create index idx_fdpzdjexirhzrmxcdwqzonhsqywyynyjzkhg on {{%entries}} (sectionId) ... done (time: 0.033s)
    > create index idx_djjosoneockvsfrcighmhwkvuozdhwhyxanv on {{%entries}} (typeId) ... done (time: 0.025s)
    > create index idx_fzpnrvlfygumbqevcoxcgytmzqsqaqnatzic on {{%entrytypes}} (name,sectionId) ... done (time: 0.033s)
    > create index idx_lmcoiynrfyrmtmzzujlpnevhkppucbopbtzp on {{%entrytypes}} (handle,sectionId) ... done (time: 0.025s)
    > create index idx_zkoaichanobwnicapwytrgceddibssdbvpho on {{%entrytypes}} (sectionId) ... done (time: 0.033s)
    > create index idx_bvvphxetsrhldudftpuwwjuwpktyuawhifav on {{%entrytypes}} (fieldLayoutId) ... done (time: 0.025s)
    > create index idx_xvexccdmzibnwykisvbbszgblyoinweuygqn on {{%entrytypes}} (dateDeleted) ... done (time: 0.033s)
    > create index idx_kdirdspjqrnihoyjfkpqnqosqgrodsyiozqi on {{%fieldgroups}} (name) ... done (time: 0.025s)
    > create index idx_zsjpwrmytsrkmaiwtjqcpxpznvgxpjnjuocx on {{%fieldgroups}} (dateDeleted,name) ... done (time: 0.025s)
    > create unique index idx_dfqjbqfmhmtrphwcavusvvnvdtogvrbsuyml on {{%fieldlayoutfields}} (layoutId,fieldId) ... done (time: 0.025s)
    > create index idx_lntizgcguwqssvuzwcvlziyjqlqnrgbqawjt on {{%fieldlayoutfields}} (sortOrder) ... done (time: 0.033s)
    > create index idx_vxjkcdmqezbdmqkkcllaqucfjqrfhxcrwrfk on {{%fieldlayoutfields}} (tabId) ... done (time: 0.033s)
    > create index idx_yswmxumccoavpggcyaqkmwglclgupskivhln on {{%fieldlayoutfields}} (fieldId) ... done (time: 0.025s)
    > create index idx_nrjsojbcyfytgyeblokctazylgwseshrsthb on {{%fieldlayouts}} (dateDeleted) ... done (time: 0.034s)
    > create index idx_twqtqiwkhcszjvdzysthktigsiwzrnwlssvu on {{%fieldlayouts}} (type) ... done (time: 0.033s)
    > create index idx_zxysfjklvijkshwnpcuyouatnefgmoiatkfo on {{%fieldlayouttabs}} (sortOrder) ... done (time: 0.033s)
    > create index idx_xuttdtfnvtrwdnhnqmonhvbcwbgyxbhlhylf on {{%fieldlayouttabs}} (layoutId) ... done (time: 0.025s)
    > create index idx_wqradtbiwbrhfstmbrabmhruexelulxitzfl on {{%fields}} (handle,context) ... done (time: 0.025s)
    > create index idx_jyexftytzopubqawtmqrkynxhoumfunxrmrc on {{%fields}} (groupId) ... done (time: 0.025s)
    > create index idx_wuqzjxdtttsdtsgxpugccwqsjqrallchsbhg on {{%fields}} (context) ... done (time: 0.033s)
    > create index idx_bglstpejmjlhksmkflirbyfeiwihfpfwevfu on {{%globalsets}} (name) ... done (time: 0.025s)
    > create index idx_jxarfuyrotpttupvgjkwudmrwqfqnwnkxzwr on {{%globalsets}} (handle) ... done (time: 0.034s)
    > create index idx_aiexpeirccypgfcjhvmexjgzzcwdehyyumkl on {{%globalsets}} (fieldLayoutId) ... done (time: 0.041s)
    > create index idx_coiakilqacbkuhumfpkujvstyadthufobugt on {{%globalsets}} (sortOrder) ... done (time: 0.025s)
    > create unique index idx_athuxbwopesycjxshmlyuqcfezmnwznkmgja on {{%gqltokens}} (accessToken) ... done (time: 0.033s)
    > create unique index idx_xuqqvpsmrxmiptkqzayqvpgorbrbxsmqaecm on {{%gqltokens}} (name) ... done (time: 0.033s)
    > create index idx_rzpxvsmqllxeanfrbpsiasgqjyhimsdpqbwp on {{%matrixblocks}} (ownerId) ... done (time: 0.033s)
    > create index idx_kmwuqzevherlhlxrguhcipldoauciivirlnh on {{%matrixblocks}} (fieldId) ... done (time: 0.034s)
    > create index idx_ixpuyrkkmxwwxvloemaowogmouxalawcbhub on {{%matrixblocks}} (typeId) ... done (time: 0.025s)
    > create index idx_tgjewersrvaigsqtqnamdmvcmudnkztmknrr on {{%matrixblocks}} (sortOrder) ... done (time: 0.058s)
    > create index idx_qdmesvveupemwpghiruwdradtgpvvbkutbym on {{%matrixblocktypes}} (name,fieldId) ... done (time: 0.025s)
    > create index idx_duoesrpusmckognwpydoicrhibldpvngoisi on {{%matrixblocktypes}} (handle,fieldId) ... done (time: 0.025s)
    > create index idx_summhtvpnlnkcwdwqirvvhzojhyuzhueewbt on {{%matrixblocktypes}} (fieldId) ... done (time: 0.034s)
    > create index idx_juipogbzxflrsaciacmdwjqfdhcoyxomjooy on {{%matrixblocktypes}} (fieldLayoutId) ... done (time: 0.025s)
    > create unique index idx_cmtrwnkerfwiqsdopupasaqdzjlktcphivcv on {{%migrations}} (track,name) ... done (time: 0.033s)
    > create unique index idx_blvayikacdmjqmigfbmjfjfbdjiphcqbmntm on {{%plugins}} (handle) ... done (time: 0.025s)
    > create index idx_pahqkiiyjfadyjepbkxwuqyjtozuvoyqylny on {{%queue}} (channel,fail,timeUpdated,timePushed) ... done (time: 0.033s)
    > create index idx_eisqnxcjyingxdalghgakjtisownvfzfxlvo on {{%queue}} (channel,fail,timeUpdated,delay) ... done (time: 0.033s)
    > create unique index idx_qrxfjydmgewtqgxhclglgxjjsucfvkbvmgdx on {{%relations}} (fieldId,sourceId,sourceSiteId,targetId) ... done (time: 0.034s)
    > create index idx_fpgjbsvhedewsvykeczhwkhsppfyoeuftxda on {{%relations}} (sourceId) ... done (time: 0.025s)
    > create index idx_fwaqdlpoorwhibnrsawdxbxuthyrhgzkwezh on {{%relations}} (targetId) ... done (time: 0.034s)
    > create index idx_sdvtvbsxfayazjuydazpixevylcyklnjhvsr on {{%relations}} (sourceSiteId) ... done (time: 0.025s)
    > create unique index idx_ebdqkpgrtynxfjucebzxlmcckmlyissjcvsm on {{%revisions}} (sourceId,num) ... done (time: 0.025s)
    > create index idx_yehbbljygbamfyiafibnlyrfumirumnutmel on {{%sections}} (handle) ... done (time: 0.025s)
    > create index idx_abmgeiadoguonjbzgwjfolvvswhapcdqejuq on {{%sections}} (name) ... done (time: 0.034s)
    > create index idx_gpgmhroxrpywoilkgxbfcpvtiebnfvlfmtnn on {{%sections}} (structureId) ... done (time: 0.033s)
    > create index idx_wgactasuggvpjgnfugirmypraxbrafilenms on {{%sections}} (dateDeleted) ... done (time: 0.025s)
    > create unique index idx_ooclhukhyiyuofnaukagwclcvxntlmadaddf on {{%sections_sites}} (sectionId,siteId) ... done (time: 0.033s)
    > create index idx_ypnbbkcpfkrzsnwmobemdzribqozaflfsxln on {{%sections_sites}} (siteId) ... done (time: 0.025s)
    > create index idx_ynmliuergytoifrmyhoioavnbjpkrzahqzaz on {{%sessions}} (uid) ... done (time: 0.033s)
    > create index idx_eudupyccxudnuniqbvpsgzedjkmhrbuvqdts on {{%sessions}} (token) ... done (time: 0.025s)
    > create index idx_cwfanihabdmbudomcaticwnedjcrezdbfttn on {{%sessions}} (dateUpdated) ... done (time: 0.033s)
    > create index idx_edghrvceiyiksnrartramhyrooxtuobopzvq on {{%sessions}} (userId) ... done (time: 0.041s)
    > create unique index idx_uaegumyrxlthuphwwzvsjocspjjqldnfbeae on {{%shunnedmessages}} (userId,message) ... done (time: 0.033s)
    > create index idx_dgkphttbosmqkjrxkfuhcsuwioizjyalidpg on {{%sites}} (dateDeleted) ... done (time: 0.034s)
    > create index idx_oaukairfatwudopoychrrimvkfamzmoguuvu on {{%sites}} (handle) ... done (time: 0.041s)
    > create index idx_tdspyppqqozyhxmuwlumnayomzmhjpzjmnvy on {{%sites}} (sortOrder) ... done (time: 0.025s)
    > create index idx_aqirrzkwdsebrrhrspidbbwzibatylgsjlwi on {{%sitegroups}} (name) ... done (time: 0.033s)
    > create unique index idx_zzypgtoqzlajretpigvgkasixielfvtxwmdy on {{%structureelements}} (structureId,elementId) ... done (time: 0.042s)
    > create index idx_ahfgbxxzojqbcetqitomghungxnymyuqpesd on {{%structureelements}} (root) ... done (time: 0.033s)
    > create index idx_fmtymktbltpyuiixdppbzqmcgeiwglctguaf on {{%structureelements}} (lft) ... done (time: 0.034s)
    > create index idx_vivzfpklsplppmmaxdmfghalsonmoexglsgi on {{%structureelements}} (rgt) ... done (time: 0.033s)
    > create index idx_boqpxvmvtpmupwicpzyhzpelqygrsgeyiudg on {{%structureelements}} (level) ... done (time: 0.034s)
    > create index idx_geevcfspawlvvfcexnutozndxsonbjxkzeqt on {{%structureelements}} (elementId) ... done (time: 0.033s)
    > create index idx_uxgeulyjqvkrbhlhuilsijevbjzgepsqmksa on {{%structures}} (dateDeleted) ... done (time: 0.025s)
    > create index idx_pkyufdiypdhzuhbnylchmjpbvgumdhxxumej on {{%taggroups}} (name) ... done (time: 0.041s)
    > create index idx_yphosrhnudwsiyrbdypzcimgcuhodgtyxumv on {{%taggroups}} (handle) ... done (time: 0.034s)
    > create index idx_opppasmhukeuljsierkqdqzctutjsmaorzbn on {{%taggroups}} (dateDeleted) ... done (time: 0.031s)
    > create index idx_yurrevevorsvrcncpoyljcrdcfkiumsderit on {{%tags}} (groupId) ... done (time: 0.036s)
    > create index idx_bmunwwdtnydmiipegjyyfakbhdnzeinhuiva on {{%templatecacheelements}} (cacheId) ... done (time: 0.025s)
    > create index idx_ezsglstjqpjmkdzxokrcgrfpjwqjrgsbpdtx on {{%templatecacheelements}} (elementId) ... done (time: 0.033s)
    > create index idx_dqukgyaagnjgnbnuvzwizzfflqczfteefygt on {{%templatecachequeries}} (cacheId) ... done (time: 0.034s)
    > create index idx_muftcmxljzhteeibuefvenwspnykraavpzdz on {{%templatecachequeries}} (type) ... done (time: 0.033s)
    > create index idx_lskhwhxpjtwkezetdopzhnqfrmphnfsmpwfk on {{%templatecaches}} (cacheKey,siteId,expiryDate,path) ... done (time: 0.025s)
    > create index idx_lrjcokwzvdgsltkdugnkgkwaxeqyvzddfrad on {{%templatecaches}} (cacheKey,siteId,expiryDate) ... done (time: 0.033s)
    > create index idx_bopnvuktvpdylwrcbhbcldpiuusvnismilrb on {{%templatecaches}} (siteId) ... done (time: 0.034s)
    > create unique index idx_sqgfeqavbbvebtrasejvspmjrldwescjkrij on {{%tokens}} (token) ... done (time: 0.025s)
    > create index idx_ztalfhbkxjjvqjsxdmnazgblzoflssuksqqe on {{%tokens}} (expiryDate) ... done (time: 0.025s)
    > create index idx_euodquawzmzduiagdqkkkefdpztdygtxfpcc on {{%usergroups}} (handle) ... done (time: 0.033s)
    > create index idx_auiamfbgfnbcxgwghleeudcmpwcnjrnplamt on {{%usergroups}} (name) ... done (time: 0.042s)
    > create unique index idx_pjswqxoryvixzathilyqdyogjxuszsnuljxc on {{%usergroups_users}} (groupId,userId) ... done (time: 0.025s)
    > create index idx_gxugybpdkwaekyqaiqlhzcyjgspwhipgmkcw on {{%usergroups_users}} (userId) ... done (time: 0.034s)
    > create unique index idx_qcqfreytvqqirpykchlzucvzgzhcmkaweucw on {{%userpermissions}} (name) ... done (time: 0.033s)
    > create unique index idx_kxyqonekrvjdibmssadeqgcdnldwtjddruwn on {{%userpermissions_usergroups}} (permissionId,groupId) ... done (time: 0.033s)
    > create index idx_szxcdewymoqtlhtatbsnmwbxwummrdysithb on {{%userpermissions_usergroups}} (groupId) ... done (time: 0.033s)
    > create unique index idx_tcwwwrigvgqxgtzorombuizgtjmpybyxnfpb on {{%userpermissions_users}} (permissionId,userId) ... done (time: 0.025s)
    > create index idx_xxsouvfwjzbkplqxebjgnartxwwjhotjmway on {{%userpermissions_users}} (userId) ... done (time: 0.033s)
    > create index idx_xcvwixvtonfzyoyemjxsmqtedlqgbcglwswn on {{%users}} (uid) ... done (time: 0.025s)
    > create index idx_jwbhuuoyuipugcqyilgrcyaylhndnzywqorz on {{%users}} (verificationCode) ... done (time: 0.033s)
    > create unique index idx_mqbjjmbyetvhzrewugeaxvqxzdismkoouhdv on {{%volumefolders}} (name,parentId,volumeId) ... done (time: 0.034s)
    > create index idx_soehhvrjebbqxkrrbxhppjiuvrifmjlfgkai on {{%volumefolders}} (parentId) ... done (time: 0.033s)
    > create index idx_tovmeomadkcyjdzcpzelzsypsumpdkfgiser on {{%volumefolders}} (volumeId) ... done (time: 0.033s)
    > create index idx_prngrlhmcicxdrwywjtcefvnmdfddwbngyim on {{%volumes}} (name) ... done (time: 0.025s)
    > create index idx_tyuavttyokpeeqpwivxwjcvrzaoccizujtei on {{%volumes}} (handle) ... done (time: 0.042s)
    > create index idx_grnxqtkjslhccfowuvzhxmxrhmlbrpiisowe on {{%volumes}} (fieldLayoutId) ... done (time: 0.033s)
    > create index idx_gjwmamhupielkymhmcqspnbseeactmglrimi on {{%volumes}} (dateDeleted) ... done (time: 0.025s)
    > create index idx_przfnrbzokofnozljvofozjuriliuoptycef on {{%widgets}} (userId) ... done (time: 0.033s)
    > create index idx_qgmunnvfdfrxilsnkqxxutgnvvgvscmcgyur on {{%elements_sites}} (lower([[uri]]),siteId) ... done (time: 0.034s)
    > create index idx_ntzmzapsjolbugpgolgehjqvefzplvjehmtj on {{%users}} (lower([[email]])) ... done (time: 0.025s)
    > create index idx_jyaumsrpplctmhcmalsejlplmriilfbpzywa on {{%users}} (lower([[username]])) ... done (time: 0.034s)
    > create table {{%searchindex}} ... done (time: 0.042s)
    > add primary key pk_spyolumptrlcklwltccefnxnbwgkmezhzxgh on {{%searchindex}} (elementId,attribute,fieldId,siteId) ... done (time: 0.033s)
    > add foreign key fk_jakjezastahnulrtkmafdpkmwjdrgeneyifq: {{%announcements}} (userId) references {{%users}} (id) ... done (time: 0.002s)
    > add foreign key fk_kqzjamuufcluczravqljssqhjdzhhukwltjr: {{%announcements}} (pluginId) references {{%plugins}} (id) ... done (time: 0.001s)
    > add foreign key fk_gccvtcfattxblhqvibqcikpybxhhudweekoq: {{%assetindexdata}} (volumeId) references {{%volumes}} (id) ... done (time: 0.001s)
    > add foreign key fk_cagxeyfjafetkfiotsrytggiljqfdukagbjw: {{%assets}} (folderId) references {{%volumefolders}} (id) ... done (time: 0.001s)
    > add foreign key fk_mdodmrxwtfwtjsegrauiidsvgkaxepuhifda: {{%assets}} (id) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_snkpqisrrqfzcfkhnbxqkxlcfodtzyiefsps: {{%assets}} (uploaderId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_mgpbuzdjmzuskbppvnpaoziwoojxjgqumzje: {{%assets}} (volumeId) references {{%volumes}} (id) ... done (time: 0.001s)
    > add foreign key fk_nntxvcsoffkbhhintvtktibwqugaxfpqdziy: {{%categories}} (groupId) references {{%categorygroups}} (id) ... done (time: 0.001s)
    > add foreign key fk_vlrhsegvkmspjnmhkbhxnhytlxglieegfuwk: {{%categories}} (id) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_umepeiandejplyyphrhgnsottbxluafakaqm: {{%categories}} (parentId) references {{%categories}} (id) ... done (time: 0.001s)
    > add foreign key fk_qxonfnfyctbmadgsqsfibzrkemrvcecxaypk: {{%categorygroups}} (fieldLayoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_zbxmwaslvvwawtfxsinfwrjyulwntbsnywsr: {{%categorygroups}} (structureId) references {{%structures}} (id) ... done (time: 0.001s)
    > add foreign key fk_oaxsngnllhrjhahncwivjqoqzlvgjmadywhq: {{%categorygroups_sites}} (groupId) references {{%categorygroups}} (id) ... done (time: 0.001s)
    > add foreign key fk_dufobikvakpqcyovulfjdukmbtrqexqquiuu: {{%categorygroups_sites}} (siteId) references {{%sites}} (id) ... done (time: 0.001s)
    > add foreign key fk_migxgbgdlizecznigzavpzrecmxzdtsbgmuk: {{%changedattributes}} (elementId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_cphtfaqonzjdhxxilkcsslycumbxmpkueqdm: {{%changedattributes}} (siteId) references {{%sites}} (id) ... done (time: 0.001s)
    > add foreign key fk_qsorcehdgpvdvpkwubjxbnytyulsrukpelvh: {{%changedattributes}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_btllsjyupvlnbqjhzmkucijkpaovxgrxquts: {{%changedfields}} (elementId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_hoibpwhntxahqppbezenimqzysgpvbiclmxf: {{%changedfields}} (siteId) references {{%sites}} (id) ... done (time: 0.001s)
    > add foreign key fk_lcckrsudyzfqqmembihkyfnuonctwmqbhvje: {{%changedfields}} (fieldId) references {{%fields}} (id) ... done (time: 0.001s)
    > add foreign key fk_llowpssnwcqohfhhchnwbioqpybkgxgsamdw: {{%changedfields}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_gfyhilefigvzckcmpascdofsjvuhbnyooymd: {{%content}} (elementId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_qsjpbtxrjlcchijmxevqkjquouiluwfhzrtp: {{%craftidtokens}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_oqonekyokiqmcotzbxviecsdggzxkxwfjiju: {{%content}} (siteId) references {{%sites}} (id) ... done (time: 0.001s)
    > add foreign key fk_kuhzqdubqviqgclfqurrbmkrgzyyalqkokys: {{%drafts}} (creatorId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_idtioyvyvkpvejytbryipzaqpquhmurzvsko: {{%drafts}} (sourceId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_etthofpdbyicvzpyymgkwteapnwedqrlodnx: {{%elements}} (canonicalId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_iucqvwzgeldvgdlgqwnmsgmsasuqeoiargnx: {{%elements}} (draftId) references {{%drafts}} (id) ... done (time: 0.001s)
    > add foreign key fk_qtcuglmmfkqxagefmwpksxamevlcbpjrchdc: {{%elements}} (revisionId) references {{%revisions}} (id) ... done (time: 0.001s)
    > add foreign key fk_gnddbapgnlrowvdlmpmnomqccnlrwdgmxxgp: {{%elements}} (fieldLayoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_qjrrdmiafnosfxzisrgeojkbavhvfqxsfkhi: {{%elements_sites}} (elementId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_ojcvrkaagteiuberojqfevwtxicxjxsljsfn: {{%elements_sites}} (siteId) references {{%sites}} (id) ... done (time: 0.001s)
    > add foreign key fk_zzqbgarabbbbojmkijjyjksjyurnunwfxpcq: {{%entries}} (authorId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_hgdstderpmywdlmfgdmzxseaagzbsveznchm: {{%entries}} (id) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_gheyljplbmmbytkbwmcfuutnsrzpaypenmfe: {{%entries}} (sectionId) references {{%sections}} (id) ... done (time: 0.001s)
    > add foreign key fk_mfpsqbfmhqycqdkdllyfqcqheknavvytuqtj: {{%entries}} (parentId) references {{%entries}} (id) ... done (time: 0.001s)
    > add foreign key fk_qyfflqqdcwaxftxxtfdstdlqpheisetitknf: {{%entries}} (typeId) references {{%entrytypes}} (id) ... done (time: 0.001s)
    > add foreign key fk_vznuifqnskrtnglwwlafwntbqymciujqbker: {{%entrytypes}} (fieldLayoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_ikcpawlzqsmzblulbdqgdviobplilsebfrfe: {{%entrytypes}} (sectionId) references {{%sections}} (id) ... done (time: 0.001s)
    > add foreign key fk_ibpcbkriiuyxvwqfolhnbgomoysasslwcaeg: {{%fieldlayoutfields}} (fieldId) references {{%fields}} (id) ... done (time: 0.001s)
    > add foreign key fk_mralliwcrooyrjaghhqkpaqynfiqqhvojonc: {{%fieldlayoutfields}} (layoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_mqngaywodkhnpvhoanzltvcmulwnpcrwxkgp: {{%fieldlayoutfields}} (tabId) references {{%fieldlayouttabs}} (id) ... done (time: 0.001s)
    > add foreign key fk_wgbzccuonyrwojikyhqcdloealiqosqolarx: {{%fieldlayouttabs}} (layoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_iogdjwanwbfxepwyzvjkzidwnljuavyqzvbf: {{%fields}} (groupId) references {{%fieldgroups}} (id) ... done (time: 0.001s)
    > add foreign key fk_milskwnrnwfkqahytamofbudnmeijmoejral: {{%globalsets}} (fieldLayoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_udazocptljmvpygjmymuywpxtejntylkpfcj: {{%globalsets}} (id) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_mrclzejcszunznujrqdbknrfruyayuqfqybs: {{%gqltokens}} (schemaId) references {{%gqlschemas}} (id) ... done (time: 0.001s)
    > add foreign key fk_rrukincpjbzoeimznkjelxqyyhnicrmfugfq: {{%matrixblocks}} (fieldId) references {{%fields}} (id) ... done (time: 0.001s)
    > add foreign key fk_zerwktivokpajgrjfjgzzdcgzbsitezzjmxz: {{%matrixblocks}} (id) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_uzwzddyjplhmluepdeytgauaqokbgvfnprnw: {{%matrixblocks}} (ownerId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_rcgfuccjgoaqaztgzppyeovamavrmekmiovi: {{%matrixblocks}} (typeId) references {{%matrixblocktypes}} (id) ... done (time: 0.001s)
    > add foreign key fk_vpbxcehuvzzdywahotgnpxseqlihxueumbub: {{%matrixblocktypes}} (fieldId) references {{%fields}} (id) ... done (time: 0.001s)
    > add foreign key fk_zpgzvrirkvgssnypopkvfggdlzfhgtjzsfla: {{%matrixblocktypes}} (fieldLayoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_pcgoyiysczdgjdcibokehydmieqfcigpzpuv: {{%relations}} (fieldId) references {{%fields}} (id) ... done (time: 0.001s)
    > add foreign key fk_rxzdtojgibmmfcfgbuglzhlplogkyunhhezr: {{%relations}} (sourceId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_sxjhnbmyjseavgycmbppodhnbdbsgnotlrkz: {{%relations}} (sourceSiteId) references {{%sites}} (id) ... done (time: 0.001s)
    > add foreign key fk_ahanataostmxrhfegbqlywwgtyfygmfutvze: {{%relations}} (targetId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_xadwiinmehdwjhtwnjhppxeioqcvdttgvpvs: {{%revisions}} (creatorId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_hmacpaeykuxmjxlswceiyzhcherzvxrbqczm: {{%revisions}} (sourceId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_jtakkgcyhyialihkjdvrmveshvaynqtctevj: {{%sections}} (structureId) references {{%structures}} (id) ... done (time: 0.001s)
    > add foreign key fk_wafexvrwjfiyhgdjsgdcfmlpwznpbeeabfuh: {{%sections_sites}} (siteId) references {{%sites}} (id) ... done (time: 0.001s)
    > add foreign key fk_cqfkcltjsaumwenjsumbpnlnsiyphxbjcdwr: {{%sections_sites}} (sectionId) references {{%sections}} (id) ... done (time: 0.001s)
    > add foreign key fk_goodkxxjndgyhgbjgpuzoxczbfsyhjiicmjg: {{%sessions}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_fswesrpnrzsazuhezejxqputojdxgurkzicz: {{%shunnedmessages}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_oesnthgpnbqyyohbrqiuqidwbpfxlfkxdnjj: {{%sites}} (groupId) references {{%sitegroups}} (id) ... done (time: 0.001s)
    > add foreign key fk_cbbyvfwmellxbcvingpwzbkyrprgmoevacej: {{%structureelements}} (elementId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_sjrwrqufyobbgrmloogpckeqcmcpbytgjfuq: {{%structureelements}} (structureId) references {{%structures}} (id) ... done (time: 0.001s)
    > add foreign key fk_jjdpbwyajiqbvfbimcqxgrndrhxfnsiihjjl: {{%taggroups}} (fieldLayoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_wbygrlfateifavyxbexieqiikhcdrtzjrqqw: {{%tags}} (groupId) references {{%taggroups}} (id) ... done (time: 0.001s)
    > add foreign key fk_flkyjsrfyfjyftagjrsbfymcqqanxyugsfid: {{%tags}} (id) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_opojxyznkigupylfetvomhakywfhhgrbhvbi: {{%templatecacheelements}} (cacheId) references {{%templatecaches}} (id) ... done (time: 0.001s)
    > add foreign key fk_tqpgsrtjeysauiaqovixamunapspnxrrdpxq: {{%templatecacheelements}} (elementId) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_qwnyodosldeewtlipstnjzcornqphnsajoae: {{%templatecachequeries}} (cacheId) references {{%templatecaches}} (id) ... done (time: 0.001s)
    > add foreign key fk_xpdfgshpttpqwvntujlsdogyzgkijzbfwler: {{%templatecaches}} (siteId) references {{%sites}} (id) ... done (time: 0.001s)
    > add foreign key fk_mgoqyclqfvtbsuywsqahmstxjhndulqwfikf: {{%usergroups_users}} (groupId) references {{%usergroups}} (id) ... done (time: 0.001s)
    > add foreign key fk_bpovqxytujjwvtybfcyftngpmqchyevcrqat: {{%usergroups_users}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_xxbnobvottybsnglspuiehgrrshpfcftnsjm: {{%userpermissions_usergroups}} (groupId) references {{%usergroups}} (id) ... done (time: 0.001s)
    > add foreign key fk_icdhtadmqjvzfelvztptjujzrdxmomhijzwd: {{%userpermissions_usergroups}} (permissionId) references {{%userpermissions}} (id) ... done (time: 0.001s)
    > add foreign key fk_tmblhdlfanwpdwtqpmudxppfsfvkvexwtfpe: {{%userpermissions_users}} (permissionId) references {{%userpermissions}} (id) ... done (time: 0.001s)
    > add foreign key fk_glshjahfwdeurbaprglnerzutckudcuvdivk: {{%userpermissions_users}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_uifxjgfcdcwmjjqjavvsveqyautwgqsbackn: {{%userpreferences}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > add foreign key fk_qzssbcjiovzfrsoqedlncejezflilsdrejfs: {{%users}} (id) references {{%elements}} (id) ... done (time: 0.001s)
    > add foreign key fk_igmiranmpynsvxxfbgsutzbqknbskkldzcim: {{%users}} (photoId) references {{%assets}} (id) ... done (time: 0.001s)
    > add foreign key fk_vduwikrcanvmsuklmstuxwvfvogqofycatkx: {{%volumefolders}} (parentId) references {{%volumefolders}} (id) ... done (time: 0.001s)
    > add foreign key fk_ooxwxdeisynorubycbscsmglrcnskmcfimdf: {{%volumefolders}} (volumeId) references {{%volumes}} (id) ... done (time: 0.001s)
    > add foreign key fk_mqzisdihvrgrqwzdcpuelgitankufraqkvbo: {{%volumes}} (fieldLayoutId) references {{%fieldlayouts}} (id) ... done (time: 0.001s)
    > add foreign key fk_rolydjwqqlhiybpkoebusqtpctpkaxzncqau: {{%widgets}} (userId) references {{%users}} (id) ... done (time: 0.001s)
    > populating the info table ... done
    > saving default site data ... Exception: The table does not exist: {{%fieldgroups}} (vendor\yiisoft\yii2\db\ActiveRecord.php:438)
#0 vendor\yiisoft\yii2\db\ActiveRecord.php(469): yii\db\ActiveRecord::getTableSchema()
#1 vendor\yiisoft\yii2\db\BaseActiveRecord.php(500): yii\db\ActiveRecord->attributes()
#2 vendor\craftcms\cms\src\db\ActiveRecord.php(51): yii\db\BaseActiveRecord->hasAttribute('uid')
#3 vendor\craftcms\cms\src\services\Fields.php(337): craft\db\ActiveRecord->__set('uid', '56d5dae4-51c5-4...')
#4 vendor\craftcms\cms\src\base\ApplicationTrait.php(1673): craft\services\Fields->handleChangedGroup(Object(craft\events\ConfigEvent))
#5 vendor\craftcms\cms\src\services\ProjectConfig.php(1189): craft\console\Application->craft\base\{closure}(Object(craft\events\ConfigEvent))
#6 [internal function]: craft\services\ProjectConfig->handleChangeEvent(Object(craft\events\ConfigEvent))
#7 vendor\yiisoft\yii2\base\Component.php(628): call_user_func(Array, Object(craft\events\ConfigEvent))
#8 vendor\craftcms\cms\src\services\ProjectConfig.php(749): yii\base\Component->trigger('addItem', Object(craft\events\ConfigEvent))
#9 vendor\craftcms\cms\src\services\ProjectConfig.php(1308): craft\services\ProjectConfig->_processConfigChangesInternal('fieldGroups.56d...', false, NULL, true)
#10 vendor\craftcms\cms\src\services\ProjectConfig.php(597): craft\services\ProjectConfig->_applyChanges(Array)
#11 vendor\craftcms\cms\src\migrations\Install.php(1128): craft\services\ProjectConfig->applyConfigChanges(Array)
#12 vendor\craftcms\cms\src\migrations\Install.php(75): craft\migrations\Install->insertDefaultData()
#13 vendor\craftcms\cms\src\db\Migration.php(52): craft\migrations\Install->safeUp()
#14 vendor\craftcms\cms\src\db\MigrationManager.php(232): craft\db\Migration->up(true)
#15 vendor\craftcms\cms\src\console\controllers\InstallController.php(179): craft\db\MigrationManager->migrateUp(Object(craft\migrations\Install))
#16 [internal function]: craft\console\controllers\InstallController->actionCraft()
#17 vendor\yiisoft\yii2\base\InlineAction.php(57): call_user_func_array(Array, Array)
#18 vendor\yiisoft\yii2\base\Controller.php(181): yii\base\InlineAction->runWithParams(Array)
#19 vendor\yiisoft\yii2\console\Controller.php(184): yii\base\Controller->runAction('craft', Array)
#20 vendor\craftcms\cms\src\console\Controller.php(221): yii\console\Controller->runAction('craft', Array)
#21 vendor\yiisoft\yii2\base\Module.php(534): craft\console\Controller->runAction('craft', Array)
#22 vendor\yiisoft\yii2\console\Application.php(181): yii\base\Module->runAction('install/craft', Array)
#23 vendor\craftcms\cms\src\console\Application.php(89): yii\console\Application->runAction('install/craft', Array)
#24 vendor\yiisoft\yii2\base\Controller.php(215): craft\console\Application->runAction('install/craft', Array)
#25 vendor\craftcms\cms\src\console\Controller.php(212): yii\base\Controller->run('install/craft', Array)
#26 vendor\craftcms\cms\src\console\controllers\SetupController.php(127): craft\console\Controller->run('install/craft')
#27 [internal function]: craft\console\controllers\SetupController->actionIndex()
#28 vendor\yiisoft\yii2\base\InlineAction.php(57): call_user_func_array(Array, Array)
#29 vendor\yiisoft\yii2\base\Controller.php(181): yii\base\InlineAction->runWithParams(Array)
#30 vendor\yiisoft\yii2\console\Controller.php(184): yii\base\Controller->runAction('', Array)
#31 vendor\craftcms\cms\src\console\Controller.php(221): yii\console\Controller->runAction('', Array)
#32 vendor\yiisoft\yii2\base\Module.php(534): craft\console\Controller->runAction('', Array)
#33 vendor\yiisoft\yii2\console\Application.php(181): yii\base\Module->runAction('setup', Array)
#34 vendor\craftcms\cms\src\console\Application.php(89): yii\console\Application->runAction('setup', Array)
#35 vendor\yiisoft\yii2\console\Application.php(148): craft\console\Application->runAction('setup', Array)
#36 vendor\yiisoft\yii2\base\Application.php(392): yii\console\Application->handleRequest(Object(craft\console\Request))
#37 craft(13): yii\base\Application->run()
#38 {main}
Exception 'craft\errors\MigrationException' with message 'An error occurred while executing the "craft\migrations\Install migration: The table does not exist: {{%fieldgroups}}'

in vendor\craftcms\cms\src\db\MigrationManager.php:252

Caused by: Exception 'yii\base\InvalidConfigException' with message 'The table does not exist: {{%fieldgroups}}'

in vendor\yiisoft\yii2\db\ActiveRecord.php:438

Stack trace:
#0 vendor\yiisoft\yii2\db\ActiveRecord.php(469): yii\db\ActiveRecord::getTableSchema()
#1 vendor\yiisoft\yii2\db\BaseActiveRecord.php(500): yii\db\ActiveRecord->attributes()
#2 vendor\craftcms\cms\src\db\ActiveRecord.php(51): yii\db\BaseActiveRecord->hasAttribute('uid')
#3 vendor\craftcms\cms\src\services\Fields.php(337): craft\db\ActiveRecord->__set('uid', '56d5dae4-51c5-4...')
#4 vendor\craftcms\cms\src\base\ApplicationTrait.php(1673): craft\services\Fields->handleChangedGroup(Object(craft\events\ConfigEvent))
#5 vendor\craftcms\cms\src\services\ProjectConfig.php(1189): craft\console\Application->craft\base\{closure}(Object(craft\events\ConfigEvent))
#6 [internal function]: craft\services\ProjectConfig->handleChangeEvent(Object(craft\events\ConfigEvent))
#7 vendor\yiisoft\yii2\base\Component.php(628): call_user_func(Array, Object(craft\events\ConfigEvent))
#8 vendor\craftcms\cms\src\services\ProjectConfig.php(749): yii\base\Component->trigger('addItem', Object(craft\events\ConfigEvent))
#9 vendor\craftcms\cms\src\services\ProjectConfig.php(1308): craft\services\ProjectConfig->_processConfigChangesInternal('fieldGroups.56d...', false, NULL, true)
#10 vendor\craftcms\cms\src\services\ProjectConfig.php(597): craft\services\ProjectConfig->_applyChanges(Array)
#11 vendor\craftcms\cms\src\migrations\Install.php(1128): craft\services\ProjectConfig->applyConfigChanges(Array)
#12 vendor\craftcms\cms\src\migrations\Install.php(75): craft\migrations\Install->insertDefaultData()
#13 vendor\craftcms\cms\src\db\Migration.php(52): craft\migrations\Install->safeUp()
#14 vendor\craftcms\cms\src\db\MigrationManager.php(232): craft\db\Migration->up(true)
#15 vendor\craftcms\cms\src\console\controllers\InstallController.php(179): craft\db\MigrationManager->migrateUp(Object(craft\migrations\Install))
#16 [internal function]: craft\console\controllers\InstallController->actionCraft()
#17 vendor\yiisoft\yii2\base\InlineAction.php(57): call_user_func_array(Array, Array)
#18 vendor\yiisoft\yii2\base\Controller.php(181): yii\base\InlineAction->runWithParams(Array)
#19 vendor\yiisoft\yii2\console\Controller.php(184): yii\base\Controller->runAction('craft', Array)
#20 vendor\craftcms\cms\src\console\Controller.php(221): yii\console\Controller->runAction('craft', Array)
#21 vendor\yiisoft\yii2\base\Module.php(534): craft\console\Controller->runAction('craft', Array)
#22 vendor\yiisoft\yii2\console\Application.php(181): yii\base\Module->runAction('install/craft', Array)
#23 vendor\craftcms\cms\src\console\Application.php(89): yii\console\Application->runAction('install/craft', Array)
#24 vendor\yiisoft\yii2\base\Controller.php(215): craft\console\Application->runAction('install/craft', Array)
#25 vendor\craftcms\cms\src\console\Controller.php(212): yii\base\Controller->run('install/craft', Array)
#26 vendor\craftcms\cms\src\console\controllers\SetupController.php(127): craft\console\Controller->run('install/craft')
#27 [internal function]: craft\console\controllers\SetupController->actionIndex()
#28 vendor\yiisoft\yii2\base\InlineAction.php(57): call_user_func_array(Array, Array)
#29 vendor\yiisoft\yii2\base\Controller.php(181): yii\base\InlineAction->runWithParams(Array)
#30 vendor\yiisoft\yii2\console\Controller.php(184): yii\base\Controller->runAction('', Array)
#31 vendor\craftcms\cms\src\console\Controller.php(221): yii\console\Controller->runAction('', Array)
#32 vendor\yiisoft\yii2\base\Module.php(534): craft\console\Controller->runAction('', Array)
#33 vendor\yiisoft\yii2\console\Application.php(181): yii\base\Module->runAction('setup', Array)
#34 vendor\craftcms\cms\src\console\Application.php(89): yii\console\Application->runAction('setup', Array)
#35 vendor\yiisoft\yii2\console\Application.php(148): craft\console\Application->runAction('setup', Array)
#36 vendor\yiisoft\yii2\base\Application.php(392): yii\console\Application->handleRequest(Object(craft\console\Request))
#37 craft(13): yii\base\Application->run()
#38 {main}

Steps to reproduce

  1. ./craft setup

Additional info

brandonkelly commented 2 years ago

Not able to reproduce this. The table clearly does exist:

    > create table {{%fieldgroups}} ... done (time: 0.034s)

So it must just be a schema caching bug. Should be fixed for the next release, as the Install migration is now clearing schema caches after it finishes creating all the tables, and before it starts adding the default data.

To get the fix early, change your craftcms/cms requirement in composer.json to "dev-develop as 3.7.26" and run composer update.

Bilge commented 2 years ago

It still happens to me on dev-develop on Windows via mintty. I see absolutely no tables have been created in my database.

Also, I will add it is very frustrating to have to enter the same data at all 15 prompts every time I wish to test it. A few of the prompts load data from the previous run, but most don't (even if they did save it).

angrybrad commented 2 years ago

@Bilge Is this in WSL or are you using Cygwin?

Bilge commented 2 years ago

Cygwin (Git Bash).

angrybrad commented 2 years ago

@Bilge curious... you can reproduce it on the native Windows host machine or in WSL?

Bilge commented 2 years ago

Yes, the same thing happens under WSL1. I don't think this has anything to do with the platform.

angrybrad commented 2 years ago

@Bilge if you try it with a database name that doesn't have a space in it, do you get the same behavior? Foo\ Bar

Bilge commented 2 years ago

No, if I use a database named test, it works. It seems pretty clear, then, that the script cannot handle a database with a space in its name. Being as that's the case, I'm not sure why you cannot reproduce the issue.

brandonkelly commented 2 years ago

I tested installation with a Postgres DB named Foo Bar when looking into #10274 and it works fine on my end (using Nitro on macOS). So it’s not a problem with the Install migration or Yii.

brandonkelly commented 2 years ago

Also, I will add it is very frustrating to have to enter the same data at all 15 prompts every time I wish to test it. A few of the prompts load data from the previous run, but most don't (even if they did save it).

You can skip most of them by running php craft install rather than php craft setup. setup is mainly for storing the DB connection settings in your .env file. Once they’ve been set correctly, there’s no need to keep re-setting them.

brandonkelly commented 2 years ago

We just noticed you are using a custom schema name, craft. There’s some nuance with using a non-public schema which was not obvious from the nondescript “Database schema:” prompt: that setting is only for telling Craft what the default schema that Postgres is already configured to use is (via SHOW search_path). It won’t actually inject the schema name into generated SQL queries to force it to be used. (See https://github.com/yiisoft/yii2/issues/12763 for a long discussion about this behavior.)

I’ve just dropped the “Database schema:” prompt in favor of some logic that determines which schema is actually likely to be used by default. The command will now simply output the result.

I also updated the command to start using existing environment variable values as the prompt defaults, if available.

End result looks like this:

> php craft setup/db-creds
connecting to craft3.nitro
Which database driver are you using? (mysql or pgsql) [pgsql]
Database server name or IP address: [postgres-13-5432.database.nitro]
Database port: [5432]
Database username: [nitro]
Use the password provided by $DB_PASSWORD? (yes|no) [yes]:
Database name: [Foo\ Bar]
Database table prefix:
Testing database credentials ... success!
Using default schema "craft".
Saving database credentials to your .env file ... done
Bilge commented 2 years ago

If that's the case I can't even use this software whatsoever. As a matter of fact, the sole reason I picked this CMS was because it appeared to actually support Postgres schemas, which most other CMS completely omits support for. If that is not the case then is it worth me opening an issue to add this feature, or is it not something you care about?

brandonkelly commented 2 years ago

To be clear, you can use a non-public schema; you just need to configure Postgres to use it by default, via the search_path setting.

Usually search_path is set to "$user", public by default. "$user" refers to whotever the current user is.

So, if you want to give Craft its own schema without affecting the default schema for other applications, you just need to give Craft its own Postgres user, and then name a schema after it. For example, if the Postgres user is named craft, it would use the craft schema by default.

Bilge commented 2 years ago

I do not wish to reconfigure the search path because that impacts queries. In particular, if a table is unprefixed, it is because I expect it to be found in the public schema, but if it is not, and it is instead found in the craft schema, it will now target the wrong table (and vice versa). The whole point of having a separate schema is to avoid name conflicts, but to add them all to the search path violates this benefit by potentially causing collisions again.

brandonkelly commented 2 years ago

Another option is you could set the default schema for each new database connection, by adding this to config/app.php:

use craft\db\Connection;
use craft\helpers\App;
use yii\base\Event;

return [
    'components' => [
        'db' => function() {
            $config = App::dbConfig();
            $config['on afterOpen'] = function(Event $event) {
                /** @var Connection $db */
                $db = $event->sender;
                $schema = $db->schema->defaultSchema;
                $db->createCommand("SET search_path TO $schema;")->execute();
            };
            return Craft::createObject($config);
        },
    ],
];

It will add a new database query to every request, so it’s not ideal, but it works.

brandonkelly commented 2 years ago

It will only affect connections created by Craft.

Bilge commented 2 years ago

Yes, you're right, I redacted my comment because it was incorrect. Although it still seems incorrect to have to add this boilerplate to the config. Such functionality should be easy to enable in the software configuration. I mean, the previous assumption that specifying the schema you want to use would just work should ideally hold true.

brandonkelly commented 2 years ago

I agree, and have voiced that opinion over at https://github.com/yiisoft/yii2/issues/12763, along with a suggested fix. Out of our direct control though.

brandonkelly commented 2 years ago

(I’ve also considered adding a config setting that would run the above code automatically on connect, but it feels wrong to make it super easy to do something that causes an extra DB query per request, when the ideal solution would be to just reconfigure Postgres or use a username-based schema.

Bilge commented 2 years ago

I disagree that it's such a bad thing to issue an extra query per request. It might feel wrong, but there is probably almost no practical reason not to do it, since such a query is likely to have very little measurable overhead at all (if any). Issuing extra connections would be a different story, but once a connection is established you should feel free to issue any configuration commands as required.

brandonkelly commented 2 years ago

Fair enough… I was on the fence anyway. Just added a new setSchemaOnConnect DB connection setting, which executes the SET search_path command for you.

Composer-update to dev-develop and add this to config/db.php:

'setSchemaOnConnect' => true,
brandonkelly commented 2 years ago

Craft 3.7.27 is out now with that new DB connection setting.