Open pleodigital opened 1 week ago
Sorry for the trouble @pleodigital...
I'm curious why you are updating to Freeform 5.0.14.1. Is there a specific reason for that? There were a number of issues with the migration script earlier on that have since been ironed out.
Can you try migrating directly from 4.1.22 to 5.6.6 instead and see if the same issue occurs? 🙂
I tried a few versions, hoping one of them would work, but didn’t have much luck. In the end, for example purposes, I picked the one that caused least trouble during the update.
I also tried updating directly to 5.6.6, and it worked, but I encountered the same kind of error with the submissions, along with more database changes required. I'll list those changes below:
freeform_payments_subscriptions
freeform_rules_submit_form
table already existed in my database, so I had to remove it for the migration to passfreeform_rules_buttons
table had the same issue as aboveOh and one more thing, that is not a big thing but all my forms before the update were using Flexbox formatting template and after updating to ^5 this field in the form editor is empty so I have to set those again for each form, otherwise they fail on render.
Thanks for the update @pleodigital,
Just to confirm, with the manual fixes you made above, is everything working now? I will make a note of them and have a developer check in and see if something needs to be adjusted in the migration. 🙂
The formatting templates should have migrated correctly. Most of the formatting template paths changed for 5.0.0, so the m230101_100010_FF4to5_MigrateForms.php
migration takes care of that. However, the Flexbox and Grid templates didn't get changed until 5.6.5
in m240814_120443_RefactorGridAndFlexboxFormattingTemplatePaths.php
.
I wonder how that migration might have been skipped or didn't work correctly. 🤔
No, with the manual fixes I was able to migrate to 5.6.6
but the original issue with Submissions Tab still stands. As I said earlier the issue is probably somehow related to getElements
action since it's the one that's failing.
I managed to get the stack trace fo the error:
[
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\yiisoft\\yii2\\db\\Command.php",
"line": 1325,
"function": "convertException",
"class": "yii\\db\\Schema",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\yiisoft\\yii2\\db\\Command.php",
"line": 1186,
"function": "internalExecute",
"class": "yii\\db\\Command",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\yiisoft\\yii2\\db\\Command.php",
"line": 417,
"function": "queryInternal",
"class": "yii\\db\\Command",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\yiisoft\\yii2\\db\\Query.php",
"line": 249,
"function": "queryAll",
"class": "yii\\db\\Command",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\db\\Query.php",
"line": 252,
"function": "all",
"class": "yii\\db\\Query",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\elements\\db\\ElementQuery.php",
"line": 1649,
"function": "all",
"class": "craft\\db\\Query",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\base\\Element.php",
"line": 1242,
"function": "all",
"class": "craft\\elements\\db\\ElementQuery",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\base\\Element.php",
"line": 1192,
"function": "indexElements",
"class": "craft\\base\\Element",
"type": "::"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\controllers\\ElementIndexesController.php",
"line": 700,
"function": "indexHtml",
"class": "craft\\base\\Element",
"type": "::"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\controllers\\ElementIndexesController.php",
"line": 165,
"function": "elementResponseData",
"class": "craft\\controllers\\ElementIndexesController",
"type": "->"
},
{
"function": "actionGetElements",
"class": "craft\\controllers\\ElementIndexesController",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\yiisoft\\yii2\\base\\InlineAction.php",
"line": 57,
"function": "call_user_func_array"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\yiisoft\\yii2\\base\\Controller.php",
"line": 178,
"function": "runWithParams",
"class": "yii\\base\\InlineAction",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\yiisoft\\yii2\\base\\Module.php",
"line": 552,
"function": "runAction",
"class": "yii\\base\\Controller",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\web\\Application.php",
"line": 341,
"function": "runAction",
"class": "yii\\base\\Module",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\web\\Application.php",
"line": 640,
"function": "runAction",
"class": "craft\\web\\Application",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\craftcms\\cms\\src\\web\\Application.php",
"line": 303,
"function": "_processActionRequest",
"class": "craft\\web\\Application",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\vendor\\yiisoft\\yii2\\base\\Application.php",
"line": 384,
"function": "handleRequest",
"class": "craft\\web\\Application",
"type": "->"
},
{
"file": "C:\\xampp\\htdocs\\ecmp-www\\public_html\\index.php",
"line": 21,
"function": "run",
"class": "yii\\base\\Application",
"type": "->"
}
]
What happened?
After updating Freeform plugin from
4.1.22
to5.0.14.1
version my submissions tab returns an error.Error happens on
admin%2Factions%2Felement-indexes%2Fget-elements
action.Worth noticing might be the fact that i also witnessed an error meanwhile upgrading, error occured on deletion approach of
freefrom_payments_subscriptions
tables because of foreign key issue. Managed to get through that by manually removing foreign key fromfreefrom_payments_subscriptions_plans
table. In my project there was no payments integration.Errors and Stack Trace (if available)
How can we reproduce this?
Freeform Edition
Pro
Freeform Version
5.0.14.1
Craft Version
4.12.7
When did this issue start?
After upgrading from older Freeform version
Previous Freeform Version
4.1.22