wp-calypso icon indicating copy to clipboard operation
wp-calypso copied to clipboard

FSE: Switching template on post/page to default template/template generated by the theme failed with error "Updating failed. Invalid parameter(s): template"

Open retnonindya opened this issue 3 years ago • 35 comments

Quick summary

Cc. @vinnykaur as the first responder

Switching post/page template from "Default theme" to any template created by the theme will render the error Updating failed. Invalid parameter(s): template and the post/page can't be updated.

Steps to reproduce

  1. Create a page or post.

  2. Click the dropdown block on "Template" section. Choose the one that was created by default. In this example, I'm using "Page without title" template. Screenshot 2021-12-27 at 4 29 32 PM

  3. ... And I can confirm the template "Page without title" is a template created by the theme (Quadrat/Quadrat Black) Screenshot 2021-12-27 at 4 32 54 PM

  4. See error and failed update attempt Screenshot 2021-12-27 at 4 35 02 PM

What you expected to happen

For the post/page to be able to switch templates properly

What actually happened

Error Updating failed. Invalid parameter(s): template

Context

Customer report and both Vinny and I are able to replicate it

Simple, Atomic or both?

Simple

Theme-specific issue?

Blockbase-themes: (I'm testing it using Quadrat theme (Quadrat Black), and Vinny tested it using theme Russell)

Also reported: Zoologist

Browser, operating system and other notes

No response

Reproducibility

Consistent

Severity

No response

Available workarounds?

Yes, difficult to implement

Workaround details

The template switcheroo will work only with customized template (templates that we create from scratch)

retnonindya avatar Dec 27 '21 08:12 retnonindya

When I tried with the Russell theme, creating a custom template worked from the path:

... /wp-admin/edit.php?post_type=wp_template

But not from within the post.

Also, when I assign a custom template to a post, it shows the same error.

https://user-images.githubusercontent.com/49183855/147487930-d243ef2a-9a95-452a-96bc-033019735a16.mp4

vinnykaur avatar Dec 27 '21 15:12 vinnykaur

I got this error today when I was trying out FSE (as a part of my training) on Blockbase theme

  1. Create a page with default theme and publish it
  2. Change the template to any others - I choseHeader and Footer only from the option on the right-side toolbar in editor of the page.
  3. I see this error

image

nagpai avatar Dec 27 '21 17:12 nagpai

This is affecting a Simple Site (Premium) user with the Zoologist theme (FSE is not enabled) :

4640480-zd

  1. Created a new blank page
  2. Changed template to 'Blank'
  3. Getting error Updating failed. Invalid parameter(s): template

I was able to replicate this on my test site (Zoologist, Premium plan)

image1

hngdny avatar Dec 28 '21 03:12 hngdny

I'm seeing this on two simple sites, the one mentioned here: https://wordpress.com/forums/topic/publishing-failed-invalid-parameters-template/

and on my test site. I tried enabling FSE on a test site to see if that would fix it. It didn't make a difference.

supernovia avatar Dec 28 '21 04:12 supernovia

Another case in https://wordpress.com/forums/topic/how-to-hide-blog-page-titles-and-featured-images/?view=all, simple site using Russell theme

KokkieH avatar Dec 29 '21 14:12 KokkieH

https://wordpress.com/forums/topic/template-3/?view=all, simple site on Zoologist

KokkieH avatar Jan 03 '22 06:01 KokkieH

There's another report of this here: https://wordpress.com/forums/topic/new-post-updating-failed-invalid-parameters-template/?view=all > with the Russell theme.

aleone89 avatar Jan 03 '22 09:01 aleone89

+1 for Russel. 4649640-zd-woothemes

arinoch avatar Jan 03 '22 21:01 arinoch

I was able to replicate as well. Set to High priority.

formosattic avatar Jan 04 '22 08:01 formosattic

Tagging @Automattic/cylon and @Automattic/theam here

In the case of 4667283-zen, the user commented with the following:

The problem is not related to the theme since I tried to change the theme, it didn't change anything. I even tried changing the page template from another account.

Robertght avatar Jan 08 '22 08:01 Robertght

4673315 - zd

gabriel-fuentes avatar Jan 09 '22 23:01 gabriel-fuentes

+1 4673459-zd-woothemes

formosattic avatar Jan 10 '22 08:01 formosattic

I think this is resolved by D72778-code.

creativecoder avatar Jan 10 '22 21:01 creativecoder

I've followed up with the forum threads to ask them to try again.

KokkieH avatar Jan 11 '22 04:01 KokkieH

I created a new simple site on a free plan for Quadrat Black today. When I make edits to a template, I'm still getting the Updating failed. Invalid parameter(s): template.

essleeung avatar Jan 13 '22 09:01 essleeung

I was doing some dogfooding and found the same on the Zoologist theme:

  1. Open any published page and set the "Page without Title" template
  2. Click on Update
  3. Notice the error

Screen Shot on 2022-01-13 at 13:42:51

AtrumGeost avatar Jan 13 '22 18:01 AtrumGeost

Came here to say I've seen this as well in a few themes.

supernovia avatar Jan 14 '22 17:01 supernovia

Ok I think we got to the bottom of this. Should be fixed, please reopen if it persists!

mattwiebe avatar Jan 14 '22 22:01 mattwiebe

I have a new report of this issue in 34962329-hc

They were able to switch to the built-in "Headers and Footers Only" template, and then to one of their custom ones after that, so the user is good to go.

tvolpert avatar Mar 30 '22 14:03 tvolpert

During some team testing, I found this error when trying to switch to a new page template on a simple site, and using the Blank Canvas theme.

jartes avatar Apr 02 '22 15:04 jartes

I am unable to replicate the issue, so it seems intermittent. @jartes are you able to replicate it consistently? If so, can you provide steps to do so?

Greatdane avatar Apr 06 '22 06:04 Greatdane

Closing this again for now, as no more reports and unable to replicate.

Greatdane avatar Apr 21 '22 06:04 Greatdane

Reopening issue. Reported in 30878508-hc

metabreakr avatar Apr 28 '22 18:04 metabreakr

Another report here: 4850193-zd-woothemes

I can reproduce the issue when creating a custom template and then trying to switch the template on the page to it.

https://user-images.githubusercontent.com/21261509/166203257-dc9ca99b-4fe1-475b-a468-de06a3f8ae57.mov

https://user-images.githubusercontent.com/21261509/166205010-8740b849-dc7f-45fd-8cf3-cedccbe6c525.mov

rw-ye avatar May 02 '22 08:05 rw-ye

Another instance of this in 5182756-zen - I checked and was able to replicate.

Theme: Blank Canvas

It looks like I was able to apply the user's Homepage template to a test page, after creating my own test template? Now what I see on the user's site is: My test-template shows the invalid paramteter(s) error when I try to select it. I am able to select the user's template. It's as if my test template being at the top of the list now lets the user's template work.

sophiegyo avatar May 04 '22 06:05 sophiegyo

📌 HOUSEKEEPING

  • Labels ✅
  • Priority ✅
  • Updated main description of report - No

📌 SCRUBBING

  • Tested on Simple ✅
  • Themes Tested: Farrow, Quadrat White, Blank Canvas

📌 FINDINGS/SCREENSHOTS/VIDEO

  • On a Personal Plan site, I tested the following themes and scenarios:

Farrow, Quadrat White, Blank Canvas with default settings - ❌ Not replicated

  • could switch a new page to any default template without error

Further Testing: Blank Canvas - ✅ Replicated

  • Sticking with Blank Canvas, I created a "new custom template" via Page Editor > New template, saved, and then returned to my page and continued to switch templates successfully - both to default and my new custom template.

  • Next, I went to the Site Editor and edited the default Home template. This moved it to the top of the Template list, and denoted I'd edited it. Then I returned to the page, and began switching templates again. Here, the issue recurred only when I selected my custom template:

Markup on 2022-05-04 at 11:36:06

Markup 2022-05-04 at 11 35 13
  • I returned once more to the page, and once again the error returned when I tried selecting the custom template for the page to use.

https://user-images.githubusercontent.com/27249804/166803680-b67e4139-8617-4f00-bf6e-fe5e05ae1eb6.mov

Further Testing: Quadrat White - ❌ Not Replicated

Last, I switched to Quadrat White once more:

  • With all default templates and no customizations made on templates, I can switch templates without issue.
  • With edits made to one of my default templates, I can still switch templates without issue.
  • Cleared customizations, then created a new custom template for the page. Can still switch templates (to new and default) without issue.
  • Edited the "Page without Title" template, then returned to page - can still switch templates without issue.
  • Edited the default "Page" template, then returned to page - still can't get the error to occur.

📌 ACTIONS

  • Marked as Triaged for Quality Squad review

cuemarie avatar May 04 '22 18:05 cuemarie

This is tough to replicate - for any future HE reports, please note the theme used, and provide as many steps you can share that would help us consistently replicate the error on a test site.

cuemarie avatar May 04 '22 18:05 cuemarie

I encountered this issue while using Twenty Twenty-Two

Screen Shot 2022-05-03 at 11 22 34

I also saw this "failed to save" message, but I am not sure if it is related:

Screen Shot on 2022-05-03 at 11:23:11

mrfoxtalbot avatar May 05 '22 09:05 mrfoxtalbot

+1 with theme Dorna, 5286915-zd-woothemes

formosattic avatar Jun 11 '22 06:06 formosattic

Also seeing this issue now on a site with the Quadrat theme.

  1. Created a new custom template in the Site Editor
  2. Tried switching a page (homepage) to the new template
  3. Observed error shown

CleanShot 2022-08-19 at 09 44 49@2x

philnick206 avatar Aug 19 '22 08:08 philnick206