JSON Error on Button Click

This forum allows users to post and respond to "How Do I Do ....." questions. The information contained in this forum has not been validated by K-Rise Systems and, as such, K-Rise Systems cannot guarantee the accuracy of the information.
Post Reply
CathyC
Posts: 472
Joined: November 16th, 2021, 11:15 am
Contact:

JSON Error on Button Click

Unread post by CathyC »

I have seen this issue in classic for a while now and it had been hard to recreate. I had a few more examples now that I could recreate and I searched in our issue history and found some good screenshots to better see all the cases.

For some it was a userdialog service that caused it and others it was ajax on for the button that was the cause.

Platform 4
Case 1
image.png
On the EASYCommerce Account Home page, click to email a user their password, progress animation shows. SetTerminateActions window shows, click Ok. go to header search bar and type a value, click search. Progress animation shows. JSON error pops up.

Case 2
image.png
This one was raised to me by a user: I was searching for a product in the item catalogue and after clicking the search button this warning box did pop up. After clicking “ok” the product was shown anyways.

Other
Case 1
I don't remember where this one happened. On a specific EASYCommerce install where a button was added to download files. Click a button that streams a file, then click any other button on the page. The invalid JSON error came up. The fix for this was to turn ajax off for the button

Paris
Case 1
Feb, March, April, July 2021, March 2022
On the checkout page, user clicks a button to place the order, but the path runs a user dialog service. An issue was found by the internal team for the UserDialog service. Fix was applied by Justin May 2022 (ref issue 0896)
image.png
image.png
Case 2
August 2022
On the catalog page filtered by a search, when trying to add an item from the grid view to cart. Not sure if this had a user dialog service in it, but this was after a fix was applied to the tenant for the user dialog service, so that shouldnt have errored anymore.
image.png
Last edited by CathyC on September 1st, 2022, 3:53 pm, edited 1 time in total. word count: 320

Tags:
Joe
Posts: 9
Joined: February 4th, 2022, 3:49 pm
Contact:

Re: JSON Error on Button Click

Unread post by Joe »

I've also seen this error on platform3 using 5.1 classic. I was never able to consistently recreate the error, but my guess was that it had something to do with the UserDialog service. I only ever got the "not valid JSON" message if UserDialog had already ran in the button.
word count: 52
CathyC
Posts: 472
Joined: November 16th, 2021, 11:15 am
Contact:

Re: JSON Error on Button Click

Unread post by CathyC »

thanks Joe! I edited my original post because the userdialog on yours reminded me of other cases I was able to put
word count: 22
SteveCap
Posts: 329
Joined: August 26th, 2021, 9:18 am
Contact:

Re: JSON Error on Button Click

Unread post by SteveCap »

Task #10755 has been created. This post will be updated when it has been completed.
word count: 15
btyrell
Posts: 29
Joined: September 8th, 2021, 2:59 pm
Contact:

Re: JSON Error on Button Click

Unread post by btyrell »

Removing the AutoComplete service from the textbox solved the issue for Platform 4 in Cathy's original post. Is there any way currently to have AutoComplete work while avoiding this issue?
word count: 31
CathyC
Posts: 472
Joined: November 16th, 2021, 11:15 am
Contact:

Re: JSON Error on Button Click

Unread post by CathyC »

We had this issue again and it was reported that it is happening frequently. This is for the paris case 2. searching from the catalog page in the header search box. We looked and this was not calling an api. it didnt have auto complete or a userdialog service
image.png
What else can we check for this?
word count: 56
shalomsims
Posts: 38
Joined: March 16th, 2022, 1:04 pm
Contact:

Re: JSON Error on Button Click

Unread post by shalomsims »

Ran into this same issue on 5.1 Classic EasyProcess.

Not sure exactly what I did. I was running UpdateAll logic using the button on the MyLists feature. My internet started running slowly around this time and I'm not sure if that helped cause an issue. It was working

Here's a link to the IDE for UpdateAll:
https://easyprocess.krisesystems.com/Pr ... rt_Control

Link to the page:
https://easyprocess.krisesystems.com/Pr ... WznmhUk32w
Screenshot 2022-10-18 134521.png
word count: 76
CathyC
Posts: 472
Joined: November 16th, 2021, 11:15 am
Contact:

Re: JSON Error on Button Click

Unread post by CathyC »

more reports of this from paris example:
image.png
I think from the login page. Appears if the session is inactive for 1 minute or so error appears
so might be related to inactivity for some time?
word count: 35
JustinVanRegenmorter
Posts: 576
Joined: August 26th, 2021, 9:56 am
Contact:

Re: JSON Error on Button Click

Unread post by JustinVanRegenmorter »

As of RunTime Revision 1106 the suspected code has a try catch to help provide a better error and prevent these JSON popups.
word count: 23
CathyC
Posts: 472
Joined: November 16th, 2021, 11:15 am
Contact:

Re: JSON Error on Button Click

Unread post by CathyC »

I dont think we have seen this in a while. I am marking it as resolved, but we can reopen later if needed

EDIT: In the past few months I had a talk with the internal team about why the latest EC didnt have the auto complete feature like 4.8 EC. I found in EASYTracker issue 256, this issue description which pointed to this forum post as the root cause. Putting the info here in case we wanted to pick that up again so its searchable. Looks like it was fixed, but never tested and the task of adding it to EC was dropped since it wasnt an immediate need.
Catalog Issues
...
-When searching, a JSON error shows up. to fix, disconnect the solr auto complete service in the search bar.
-This service was made for this client, but when I raised the json error to steve he said this was the cause.
viewtopic.php?p=1049
this issue is platform4 case 1. in looking into it, add more details to the forum post and update whether removing the autocomplete fixed it. and ask if there is a way to utilize the autocomplete in a way that it wont cause this issue
word count: 203
Post Reply