cancel
Showing results for 
Search instead for 
Did you mean: 

Getting SyntaxError: JSON

SOLVED

Getting SyntaxError: JSON

Hi,
 
I hope someone can help. I was editing a static block and i saved the block the screen flashed and it reloaded but now it does not load the list of blocks and in the browser console i am now getting this
 
SyntaxError: JSON.parse: unexpected non-whitespace character after JSON data at line 1 column 94501 of the JSON data scripts.js (line 86, col 16)
 
Why did this happen? and can it be fixed?
 
Thank You

 

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Getting SyntaxError: JSON

Found the issue in the db there were two blocks with the same id deleted on and every things back.

View solution in original post

6 REPLIES 6

Re: Getting SyntaxError: JSON

Try to delete the cache and autogenerated files: https://mage2.pro/t/33

Then redeploy the static content if you are in the production mode: https://mage2.pro/t/759

 

Re: Getting SyntaxError: JSON

Hi,

 

Thank you for the help but that did not work. I still get the

 
SyntaxError: JSON.parse: unexpected non-whitespace character after JSON data at line 1 column 94501 of the JSON data
 
any thoughts.
 
Thank you
 
http://rollflaggingtape.com/pub/media/catalog/category/Capture.PNG
 
Google console
 
Uncaught SyntaxError: Unexpected token                                                                 VM437:1
<getNodeData @ scripts.js:86
(anonymous function) @ scripts.js:116
apply @ main.js:63
bootstrap @ bootstrap.js:69
fire @ jquery.js:3099
self.fireWith @ jquery.js:3211
jQuery.extend.ready @ jquery.js:3423
completed @ jquery.js:3453

Re: Getting SyntaxError: JSON

Found the issue in the db there were two blocks with the same id deleted on and every things back.

Re: Getting SyntaxError: JSON

I also faced. thanks your hint.

Re: Getting SyntaxError: JSON

Could you share how did you fix this issue?

 

I'm getting a similar error:

https://magento.stackexchange.com/questions/230904/magento-2-cant-complete-checkout-because-of-unexp...

Re: Getting SyntaxError: JSON

Could you share how you find the problem in the database?