Automattic / jetpack

Security, performance, marketing, and design tools — Jetpack is made by WordPress experts to make WP sites safer and faster, and help you grow your traffic.
https://jetpack.com/
Other
1.59k stars 798 forks source link

Display WordPress Post Widget does not work on Atomic sites from Customizer #7665

Open wprhunt opened 7 years ago

wprhunt commented 7 years ago

Steps to reproduce the issue

Add the Display WordPress Posts Widget to an AT site via the Customizer (via Calypso) and try to add any WordPress.com blog to its settings.

Adding via WP Admin widgets screen works.

This issue does not occur on non-Atomic sites hosted on WordPress.com nor WordPress.org sites hosted elsewhere or even on Pressable.

Ticket: 642339-zd

Sites replicated on: yesterdayenchantingtoday.blog thatjetpacktest.blog

Site tested with (putting into the widget's "BlogURL": 19thct.com And any other WordPress.com blog I've tried so far

What I expected

It is able to pull the post feed from a WordPress.com site

What happened instead

We get this error message:

"An error has occurred. Please reload the page and try again."

And the widget seems to time out possibly implying an issue with REST API (suggested by someone in #jpop-support )

Screenshot: 4r8djp

kraftbj commented 7 years ago

I couldn't duplicate this on an Atomic test site. Can you confirm if you're still seeing it?

Since it is only happening on Atomic sites, I don't think it is a Jetpack issue per se, but if we can't duplicate it either way, then we can close it.

wprhunt commented 7 years ago

@kraftbj I was able to still recreate it. I tried this on thatjetpacktest.blog, an AT site using Jetpack.

I added the "Display WordPress Posts (Jetpack)" widget via Calypso's Customizer and the customizer in the wp-admin and I still get "An error has occurred. Please reload the page and try again." when adding any WordPress.com site (including http://en.blog.wordpress.com/). And even after changing themes, deactivating my other plugins and clearing cache

Theme I had been using was the "Lodestar" theme and switched it to "Dyad 2"

Plugins I deactivated:

However, I seem to have been able to "fix" it. Instead of adding the widget via the Customizer, I removed it via the Customizer and then added it via Appearance -> Widgets and I didn't get the error. I then went back to the Customizer and saw it was still giving me the error when I tried removing and re-adding the widget and got the error. Then I removed it again and widgets (Search and Flickr (Jetpack) ), re-added them all and this time "Display WordPress Posts (Jetpack)" worked and I no longer get the error.

The customer's site seems to have been fixed since. They seem to have changed themes and made other changes so I'm reaching out to them, for now, to see what has happened. Seems odd that we were both able to replicate on each of our sites.

Ticket: 642339-zd

Since I can no longer recreate, we can look at closing this one out for now.

Recreation Steps:

  1. Add "Display WordPress Posts (Jetpack)" to any sidebar in the Widgets section via the Customizer
  2. Add any WordPress site to the "Blog URL" (http://en.blog.wordpress.com/ is a good one to test with)
  3. It should start timing out and produce this error: "An error has occurred. Please reload the page and try again."

e6rl5g

jessestu commented 6 years ago

Updating this post as I can recreate it on Atomic sites and on my .org site.

I switch some of the screenshots between Customizer and Appearance > Widgets for error clarity.

WP.org Jetpack stats: WP 4.9.4 running Jetpack 5.9. Additional plugins: WooCommerce 3.3.4, VaultPress 1.9.5, Gutenberg 2.4.0, Google Authenticator 0.48, Akismet 4.0.3.

Simple site: simple site loads, Atomic loads, JP .org broken

Atomic: customizer flow broken, Appearance > Widget works on Atomic

Jetpack .org: broken on my JP .org across the board

I'm not clear on whether this should be loading or not for the Simple site and the Atomic site. It is broken on my JP .org test site.

jeherve commented 6 years ago

Broken when linked to my JP .org site broken on my JP .org across the board Broken when linked to my Atomic site with error Broken when linked to my JP .org site:

All these errors happen because of the same reason: your site is not properly connected to WordPress.com right now. You would need to fix this first, for the widget to work: https://public-api.wordpress.com/rest/v1.1/sites/138772173/posts/ If you enable WP_DEBUG on the site you should be able to find out more about what's causing the issue.

CompChris commented 6 years ago

Hi there,

I just had the same error on an Atomic site today. Same symptoms. Does not work through the Customizer, but does through the Widgets page in WP-Admin as @JesseStu reported.

imagebugjetpack

Just used my own test blog to test this in the screenshot.

A short internal discussion regarding the site that this happened on is here p1523975093000921-slack

jeherve commented 6 years ago

@CompChris It seems to work well on my end:

screenshot 2018-04-18 at 8 55 23 screenshot 2018-04-18 at 8 55 50

Could you give it another try?

jesscga commented 6 years ago

Another instance on 1136226-zen, where the widget was showing "An error has occurred" in Calypso.

Was able to add widget in wp-admin without issue.

krutidugade commented 6 years ago

Another report 3404971-hc, works from WP-Admin but Customizer

jessestu commented 6 years ago

Another instance in #4500987-hc

stale[bot] commented 5 years ago

This issue has been marked as stale. This happened because:

No further action is needed. But it's worth checking if this ticket has clear reproduction steps and it is still reproducible. Feel free to close this issue if you think it's not valid anymore — if you do, please add a brief explanation.

donalirl commented 5 years ago

Another case in #10495322-hc

cecoates commented 5 years ago

I was able to repro this on my own test sites consistently.

The solution is a bit weird.

If you try to add the widget via the Customizer, it'll give you the error described above. "An error has occured".

If you go to WP Admin, and add the widget via Appearance->Widgets, it seems to work.

Then, if you open the Customizer again, you can add it as normal.

Screen Shot on 2019-05-24 at 14_42_11

Screen Shot on 2019-05-24 at 14_47_00

stale[bot] commented 4 years ago

This issue has been marked as stale. This happened because:

No further action is needed. But it's worth checking if this ticket has clear reproduction steps and it is still reproducible. Feel free to close this issue if you think it's not valid anymore — if you do, please add a brief explanation.

vajrasar commented 4 years ago

Another instance: #2721727-zen

The blog URL always gives an "invalid Blog URL" error when used in the Display WordPress Posts (Jetpack) widget through customizer.

User the same URL through wp-admin and it works.

tanjoymor commented 3 years ago

Another instance: #27932922-hc (also confirmed the issue on my test AT site) - work around from WP Admin does work... but... after the unified navigation rolls out for customers that won't be an easy location to get to.