Skip Navigation

[Resolved] Fatal Error Displaying Post After Upgrade to Layouts 2.3 RC2

This support ticket is created 6 years, 6 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- - 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00
- - - - - - -

Supporter timezone: Asia/Ho_Chi_Minh (GMT+07:00)

This topic contains 17 replies, has 4 voices.

Last updated by aaronM-9 6 years, 6 months ago.

Assisted by: Beda.

Author
Posts
#861456

I have started receiving the following fatal error when trying to display a post on the front-end (post-type "Group"):

PHP Fatal error: Uncaught Error: Class 'Toolset_Relationship_Definition_Repository' not found in...

Is this because I have not yet run the relationships migration? I was a little nervous to run it because it's telling me that pretty much every form that has a parent post ID to store may have backwards compatibility issues. To correct these, do I need to update the form field that stores data to the _wpcf_belongs field? What do I replace this code with? I don't see any instructions on what to do with this. Thanks.

- Aaron

PS - I'm now on Forms 2.0 RC2, Layouts 2.3 RC2, Views 2.6 RC3, and Types 3.0 RC2.

#862275

Hi, I just downloaded the Duplicator package and installed it locally. I deactivated all plugins except Toolset plugins and basic WooCommerce, and I'm not able to replicate the Fatal Error on this page: /group/arlington-secular-homeschoolers/

Is this where you see the fatal error? Can you try the following troubleshooting steps?
- Temporarily deactivate all plugins except Types and Views.
- Test again. If the problem is resolved, please reactivate other Toolset plugins one by one and test each time. If the problem is still not appearing, activate other plugins one by one until the Fatal Error returns.
- If the problem was not resolved, then we need to do some more investigation. There may be a difference between our test environments that is contributing to the problem.

#870074

Okay I disabled all plugins except Error Log Monitor, Layouts, Types, and Views and the Arlington Secular Homeschoolers page started displaying content again. The page stopped working again once I activated Toolset Forms.

- Aaron

#870075
temp.jpg

PS - I also noticed that I get an error message when editing forms now, which didn't start until I upgraded to the latest beta release. For example, when I try to click on "Auto Generate Form" it says "Form Type or Post Type is not set."

- Aaron

New threads created by Christian Cox and linked to this one are listed below:

https://toolset.com/forums/topic/form-type-or-post-type-is-not-set-error-when-using-the-autogenerate-button-in-cred/

#870146

It all seems somehow related to relationships. I'd like to run the migration but I'm not sure how to fix my forms. For example, what do I do with the example code below? Does this go away or get replaced with something else? The migration wizard said all my forms might not be backwards compatible because of the "belongs" fields.


[cred_field field='_wpcf_belongs_product-listing_id' value='' urlparam='param-productid' class='hidden' output='bootstrap']

Thanks.

- Aaron

#870149
Screen Shot 2018-05-09 at 3.40.52 PM.png
Screen Shot 2018-05-09 at 3.40.45 PM.png

I must be misunderstanding the problem. I just checked on your site here:
hidden link

The page is loading without any fatal errors, as far as I can see. Toolset Forms is active. What am I missing?

#870187
temp3.jpg
temp2.jpg
temp1.jpg

No worries. I've attached 3 screenshots:

temp1.jpg - shows what displays with most plugins disabled, including Forms
temp2.jpg - shows what displays when Forms is activated (no content!)
temp3.jpg - show one of many entries in the debug log

#872971

Are we testing as different Users? I'm not able to replicate the error you're seeing. I'll activate private reply fields here again so you can share a different User login if necessary.

#873075

Weird. You're right - the problem is only happening when logged in as Admin and not Toolset. I don't see the private form. If you can send, I will provide different credentials.

#873081

I just modified the admin User's password directly in the DB, no problem. I'm able to replicate the issue now, I'll investigate in more detail.

#873489

Well I see it's a somewhat complex design with several nested Views, so I created a new Page and inserted the CRED form shortcode directly into that content. The error can be seen in this simpler setup, so I must escalate this to my 2nd tier support team for further investigation. I'll update you as soon as I have information to share.

#873524

Thanks. Sorry for the complexity. Maybe at some point I'll find a more streamlined way of accomplishing what I want without needing custom programming (I'm still new to both Toolset and WordPress).

I'll be interested to see what they find. Hoping to get some resolution before the weekend since those are my most valuable chunks of time for making progress on development of the site.

Cheers.

- Aaron

#873644

I didn't mean to imply that your setup was incorrect or overly complex, just that I was able to eliminate some of those nested Views layers as contributing to the issue 🙂 I'll keep you posted.

#876857

Hi Christian,

Do you have any sense of whether or not a resolution could be reached by the weekend? Without the ability to work on forms, I'm grinding to a halt on development and I typically use the weekend to get in full days of work.

I understand if resolution can't be reached in time, but if it can't would you be able to provide me some guidance on the proper way to transition forms to the new system of managing relationships? Specifically, I need to know what to do with the fields such as this:


[cred_field field='_wpcf_belongs_product-listing_id' value='' urlparam='param-productid' class='hidden' output='bootstrap']

Do these input fields get replaced with something else? It's unclear from the documentation I've read. Once I know this, I would like to try migrating my relationships and see if this resolves the issue on this thread. Thanks.

- Aaron

#891480

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi Aaron

Christian is on holiday and I spotted your reference to this in your other thread with Shane.

I don't have any news about the issue you reported specifically, but just wanted to clarify for you that...

a CRED form with a parent field selector in the old format (using _wpcf_belongs_parent-slug_id) will continue to work after upgrading to the RCs and running the migration wizard. CRED includes a compatibility layer to handle this legacy format.

If you are making changes to your form anyway then re-generating the output you would notice that the format of the field changes, but functionally you shouldn't see any differences.