Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FSE: Pages with autosaves cannot be previewed [2] #35484

Closed
apeatling opened this issue Aug 16, 2019 · 6 comments
Closed

FSE: Pages with autosaves cannot be previewed [2] #35484

apeatling opened this issue Aug 16, 2019 · 6 comments
Assignees
Labels
[Goal] Full Site Editing [Pri] BLOCKER Requires immediate attention. [Type] Bug When a feature is broken and / or not performing as intended

Comments

@apeatling
Copy link
Member

The easiest way to reproduce this is to preview any page one time, since this will trigger an autosave (but I don’t understand why, there are no changes in the content. This also makes the issue with the revisions above more noticeable).

The second time you try to preview a page, the modal will show a gray background.

@apeatling apeatling added [Goal] Full Site Editing [Pri] BLOCKER Requires immediate attention. [Type] Bug When a feature is broken and / or not performing as intended labels Aug 16, 2019
@glendaviesnz glendaviesnz self-assigned this Aug 19, 2019
@glendaviesnz
Copy link
Contributor

glendaviesnz commented Aug 19, 2019

Initial investigation of this shows that it is not FSE site specific. The same error seems to occur on any Simple or Atomic site when following the above steps.

For some reason the /wp-calypso/apps/wpcom-block-editor/src/calypso/iframe-bridge-server.js is sending a null preview url if a page has an autosave. Just need to work out how to debug the iframe-bridge-server so I can work out why this is.

@glendaviesnz
Copy link
Contributor

glendaviesnz commented Aug 19, 2019

Got some debugging into iframe-bridge-server and now suspect it is something to do with the following in /wp-content/plugins/gutenberg/packages/editor/src/store/reducer.js

case 'REQUEST_POST_UPDATE_START':
	// Invalidate known preview link when autosave starts.
	if ( state && action.options.isPreview ) {
		return null;
	}

as in some instances (but not all it seems) related to autosaves the getEditedPostPreviewLink selector returns null, because the editorState.previewLink is null. Still trying to work out why that is, but if that situation rings any bells with you let me know.

@glendaviesnz
Copy link
Contributor

glendaviesnz commented Aug 19, 2019

some potentially useful information here which I haven't had chance to read through yet WordPress/gutenberg#7179 & WordPress/gutenberg#7852

@glendaviesnz
Copy link
Contributor

glendaviesnz commented Aug 19, 2019

Calypsoify is definitely still displaying the behaviour noted here - WordPress/gutenberg#7852 (comment)

Screen Shot 2019-08-19 at 10 22 54 PM

which is supposed to have been fixed in WordPress/gutenberg#7945. I can't replicate the issue in block editor in wp-admin, only in calypsoify - which is running a version of the editor that should include the above fix. Will do some more digging tomorrow.

@glendaviesnz
Copy link
Contributor

Duplicate issue - #33799

@gwwar gwwar changed the title FSE: Pages with autosaves cannot be previewed FSE: Pages with autosaves cannot be previewed [2] Aug 26, 2019
@glendaviesnz
Copy link
Contributor

fixed by #35824

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Goal] Full Site Editing [Pri] BLOCKER Requires immediate attention. [Type] Bug When a feature is broken and / or not performing as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants