Unexpected error found when trying to post – YOAST is causing it!
-
Hello, I’m experiencing the same errors as some other users, but since none of the answers helped me, here I am!
Out of nowhere, while trying to create a new post, I’ve started to get the following unexpected error:
TypeError: Cannot read property 'SnippetEditor' of undefined at https://ruinaacesa.com.br/wp-content/plugins/wordpress-seo/js/dist/block-editor-1611.js:1:141386 at zj (https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:13:24396) at Th (https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:10:10413) at tj (https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:10:10342) at Te (https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:10:7238) at https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:7:1114 at unstable_runWithPriority (https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react.min.js?ver=16.13.1:2:7938) at Da (https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:7:824) at Pg (https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:7:1060) at ha (https://ruinaacesa.com.br/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:7:995)I’ve already checked the versions – both WordPress (5.7.1) and Yoast SEO (16.1.1) are updated and I’ve already installed the Health Check & Troubleshooting application, and it was throughout the troubleshooting mode is that I ensured that the problem was in the Yoast SEO indeed (with all plugins turned off, I could post normally; turning Yoast on would give me the error message). What can I do other than – I’d like not to – stop using the plugin? Thanks in advance.
-
This topic was modified 5 years, 2 months ago by
James Huff.
-
This topic was modified 5 years, 2 months ago by
Yui. Reason: please use CODE button for code formatting
The page I need help with: [log in to see the link]
-
This topic was modified 5 years, 2 months ago by
-
Also reporting that I have this error but only on our client’s production environment. Can’t replicate locally or in dev and staging environments. Just to be sure this wasn’t a configuration error, I pulled a copy of the production database and updated URLs to test locally. Still can’t replicate outside of the production environment.
I updated Chrome (on Mac 10.15.7) to latest version, cleared cache and cookies, tried firefox, the issue still remains. The strange part was the client reported this, I couldn’t replicate at first and then it showed up for me. Some of my co-workers can’t replicate it.
This appears to be around the Snippet Preview and the meta description? This is a bit of a puzzling one..
Having the same issue. Here’s what’s in the console. Chrome: 90.0.4430.85. Windows 10 latest version. WordPress 5.7.1.
Uncaught SyntaxError: Invalid or unexpected token react-dom.min.js?ver=16.13.1:9 TypeError: Cannot read property 'SnippetEditor' of undefined at block-editor-1611.js:1 at zj (react-dom.min.js?ver=16.13.1:13) at Th (react-dom.min.js?ver=16.13.1:10) at tj (react-dom.min.js?ver=16.13.1:10) at Te (react-dom.min.js?ver=16.13.1:10) at react-dom.min.js?ver=16.13.1:7 at unstable_runWithPriority (react.min.js?ver=16.13.1:2) at Da (react-dom.min.js?ver=16.13.1:7) at Pg (react-dom.min.js?ver=16.13.1:7) at ha (react-dom.min.js?ver=16.13.1:7) Me @ react-dom.min.js?ver=16.13.1:9 Jh.f.componentDidCatch.c.callback @ react-dom.min.js?ver=16.13.1:10 Wg @ react-dom.min.js?ver=16.13.1:7 oj @ react-dom.min.js?ver=16.13.1:9 Aj @ react-dom.min.js?ver=16.13.1:11 unstable_runWithPriority @ react.min.js?ver=16.13.1:2 Da @ react-dom.min.js?ver=16.13.1:7 ab @ react-dom.min.js?ver=16.13.1:10 Te @ react-dom.min.js?ver=16.13.1:10 (anonymous) @ react-dom.min.js?ver=16.13.1:7 unstable_runWithPriority @ react.min.js?ver=16.13.1:2 Da @ react-dom.min.js?ver=16.13.1:7 Pg @ react-dom.min.js?ver=16.13.1:7 ha @ react-dom.min.js?ver=16.13.1:7 Ja @ react-dom.min.js?ver=16.13.1:13 ch @ react-dom.min.js?ver=16.13.1:8 e @ data.min.js?ver=9430…126df689839bb96b9:1 t @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 p @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 dispatch @ data.min.js?ver=9430…126df689839bb96b9:1 n @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 r.any @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 Promise.then (async) (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 c @ redux-routine.min.js…097c6fbe95625e2fb:1 t @ redux-routine.min.js…097c6fbe95625e2fb:1 r.iterator @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 r.any @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 n @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 r.any @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 n @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 c @ redux-routine.min.js…097c6fbe95625e2fb:1 t @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ editor.min.js?ver=db…b432a2a5d7898e51d:1 Bh @ react-dom.min.js?ver=16.13.1:9 oj @ react-dom.min.js?ver=16.13.1:9 Aj @ react-dom.min.js?ver=16.13.1:11 unstable_runWithPriority @ react.min.js?ver=16.13.1:2 Da @ react-dom.min.js?ver=16.13.1:7 ab @ react-dom.min.js?ver=16.13.1:10 Te @ react-dom.min.js?ver=16.13.1:10 (anonymous) @ react-dom.min.js?ver=16.13.1:7 unstable_runWithPriority @ react.min.js?ver=16.13.1:2 Da @ react-dom.min.js?ver=16.13.1:7 Pg @ react-dom.min.js?ver=16.13.1:7 ha @ react-dom.min.js?ver=16.13.1:7 Ja @ react-dom.min.js?ver=16.13.1:13 ch @ react-dom.min.js?ver=16.13.1:8 e @ data.min.js?ver=9430…126df689839bb96b9:1 t @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 p @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 dispatch @ data.min.js?ver=9430…126df689839bb96b9:1 n @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 Promise.then (async) (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 Promise.then (async) (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 r.any @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 n @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 r.any @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 n @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 r.any @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 n @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 r.any @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 c @ redux-routine.min.js…097c6fbe95625e2fb:1 t @ redux-routine.min.js…097c6fbe95625e2fb:1 r.iterator @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 e @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 c @ redux-routine.min.js…097c6fbe95625e2fb:1 t @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ redux-routine.min.js…097c6fbe95625e2fb:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 tryCatch @ wp-polyfill.min.js?ver=7.4.4:1 invoke @ wp-polyfill.min.js?ver=7.4.4:1 t.<computed> @ wp-polyfill.min.js?ver=7.4.4:1 n @ data.min.js?ver=9430…126df689839bb96b9:1 c @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 ne @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 tryCatch @ wp-polyfill.min.js?ver=7.4.4:1 invoke @ wp-polyfill.min.js?ver=7.4.4:1 t.<computed> @ wp-polyfill.min.js?ver=7.4.4:1 n @ data.min.js?ver=9430…126df689839bb96b9:1 c @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 setTimeout (async) (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 tryCatch @ wp-polyfill.min.js?ver=7.4.4:1 invoke @ wp-polyfill.min.js?ver=7.4.4:1 t.<computed> @ wp-polyfill.min.js?ver=7.4.4:1 n @ data.min.js?ver=9430…126df689839bb96b9:1 c @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 f @ data.min.js?ver=9430…126df689839bb96b9:1 s @ data.min.js?ver=9430…126df689839bb96b9:1 c @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ edit-post.min.js?ver…3459a7d6f527e1f90:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 s @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 (anonymous) @ data.min.js?ver=9430…126df689839bb96b9:1 Ge @ data.min.js?ver=9430…126df689839bb96b9:1 sr @ edit-post.min.js?ver…3459a7d6f527e1f90:1 we @ react-dom.min.js?ver=16.13.1:8 zj @ react-dom.min.js?ver=16.13.1:13 Th @ react-dom.min.js?ver=16.13.1:10 tj @ react-dom.min.js?ver=16.13.1:10 Te @ react-dom.min.js?ver=16.13.1:10 Ja @ react-dom.min.js?ver=16.13.1:13 md @ react-dom.min.js?ver=16.13.1:12 (anonymous) @ react-dom.min.js?ver=16.13.1:12 Rh @ react-dom.min.js?ver=16.13.1:10 nd @ react-dom.min.js?ver=16.13.1:12 I.render @ react-dom.min.js?ver=16.13.1:13 br @ edit-post.min.js?ver…3459a7d6f527e1f90:1 (anonymous) @ post.php?post=15436&action=edit:334-
This reply was modified 5 years, 1 month ago by
markd33. Reason: added hidden errors
It’s definitely strange that it happens only in the production environment and not in any of your local or staging environments, and that it happens for some of your co-workers and not for others.
Could you provide us with the exact version of Chrome and MacOS you are using?
Did you also perform a conflict check to see if there wasn’t any conflicting plugin or theme? Do you also have the SSO or Endurance Page Cache plugin on your site?
—
Hi @markd33
Thanks for reporting and providing us with that information. Another user previously did report that updating to the latest Chrome version resolved the issue for them. Could you also perform a conflict check and see if it still occurs with a default setup?
I believe I found the source of the issue. I have another WP installation that is working ok. The full JS file is being served.
The file that is throwing the error on my other server is truncated. I double checked that the file was complete by examining the JS file through the plugin editor, and it is ok. When I look at the file through the URL, served by the server, it is truncated. You can see it here:
The full file is 78K. This file is only 54K. So it must be an HTTP server setting that is limiting the full file from being served? This WP installation is on a shared server, so I’ll have to see what I can do from my end.
Hi @awhig,
You’re correct. That JS file isn’t loading correctly.
We received similar reports from other users in premium support and noticed that the only thing in common is that all websites are running the Imperva CDN. We see that the site collectededitions.com is also running Imperva CDN. Can you please try clearing the Imperva CDN cache and check if the problem resolves?
If the problem persists after clearing the cache, we’d kindly ask you to contact Imperva support. They should be able to investigate if there’s any CDN setting that may be cutting off the output of the Yoast JavaScript file.
Let us know if the above suggestions help you fix the issue.
@mikes41720 I can confirm we tested it happens even after conflict testing. I can also confirm we are using Imperva. I’m working with Corporate to see if they can help.
We are using Bluehost. I believe Imperva is implemented by them. There are some controls under the performance tab for the site. I tried clearing the cache. I also tried turning off the caching via their controls, but did not see any change. In fact, I could still see the Imperva tag in the response headers after turning caching off. Not sure how exactly to turn off Imperva. Will open a ticket with bluehost.
I worked with my corporate office to get Imperva to disable Minification of code (and clearing of cache).
That seemed to have resolved the issue. It was altering JavaScript for Yoast somehow causing this issue.
Ok. I figured it out. On our Bluehost account, we have
“Global Sitelock CDN/WAF Premium”. In the sitelock dashboard, under “Settings”, “Trueshield Settings”, there is a “Purge Cache” button. Clicking that, and going back to the JS file, the complete file was served.Very maddening to find this. Bluehost tech support, did not know the connection between Sitelock CDN and Imperva. Even after I fixed the issue, he insisted Imperva was something else. My theory is that Sitelock CDN is outsourced to Imperva. Maybe someone knows for sure.
**** UPDATE. ***
The file gets served fully once or twice, then reverts back to the incomplete version. If I clear the Sitelock cache again, it works once or twice, then incomplete file gets served again. I have no idea what is going on.
*** END UPDATE ***
Also verifying that our client’s CDN Imperva had a bad cache of the file which is why we couldn’t replicate the issue.
Clearing CDN cache then busting browser cache did the trick for us.
E.g. after clearing your CDN cache (or any cache if you are using it), then navigate to the file with a query param
https://YOURSITE.com/wp-content/plugins/wordpress-seo/js/dist/yoast/search-metadata-previews-1611.js?testAfter clearing the Sitelock cache. It works once, and then reverts back to the truncated version.
Argh.
-
This reply was modified 5 years, 1 month ago by
awhig.
Ok. I was able to permanently fix the issue by going to SiteLock, and under Settings, Traffic Routing, turn off “Use Trueshield for prevention”.
Ok. Now I’m mad. It worked for several hits, but then reverted back after I checked a few minutes later. Going to fully turn off sitelock now, and see if that does it.
I set it to “Temporarily Bypass Sitelock’s network” and that didn’t help. Same behavior. I purge the cache and it works for one hit. Then reverts to the truncated file. Interestingly, the x-cdn header still shows Imperva, even though I turned off Sitelock I thought.
-
This reply was modified 5 years, 1 month ago by
awhig.
@markd33 Thanks for confirming that disabling the minification and clearing the cache corrected the issue for you.
@awhig After clearing the CDN cache did you try the suggestion that @brainfestation posted in regards to navigating to the JavaScript file with a query parameter such as
https://collectededitions.com/wp-content/plugins/wordpress-seo/js/dist/yoast/search-metadata-previews-1611.js?testI’m having the same issue as @amiltondeazevedo
Error:
TypeError: Cannot read property 'SnippetEditor' of undefined at https://clinicadeconteudo.com.br/wp-content/plugins/wordpress-seo/js/dist/block-editor-1611.js:1:141386 at zj (https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react-dom.min.js:233:136) at Th (https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react-dom.min.js:152:223) at tj (https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react-dom.min.js:152:152) at Te (https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react-dom.min.js:146:151) at https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react-dom.min.js:61:68 at unstable_runWithPriority (https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react.min.js:25:260) at Da (https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react-dom.min.js:60:280) at Pg (https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react-dom.min.js:61:14) at ha (https://c0.wp.com/c/5.7.1/wp-includes/js/dist/vendor/react-dom.min.js:60:451)In the troubleshooting mode, just the Yoast plugin is causing the problem. All the versions are updated, either related to WordPress or chrome. The cache is cleared.
Just by disabling Yoast I can back to use the tools and edit things.
I was considering the premium version but in this scenario, I’m not so sure.
I appreciate any help,
Thanks
-
This reply was modified 5 years, 1 month ago by
The topic ‘Unexpected error found when trying to post – YOAST is causing it!’ is closed to new replies.