Jetpack: Gutenberg: Tags Added to Pages and Portfolio Projects are Converted to Numbers

Created on 7 Mar 2019  路  36Comments  路  Source: Automattic/jetpack

Some WP.com themes add Tags to Pages and Portfolio Projects, usually for featured content. When a Tag is added to a Portfolio Project, it is converted to a string of numbers. I was able to reproduce on WP.com simple sites, but not AT sites.

Steps to reproduce

  1. On a WP.com simple site, activate the Rebalance theme.
  2. Go to My Site > Portfolio and add a new Portfolio Project.
  3. Add a Tag to the Portfolio Project.
  4. Publish or Update the Portfolio Project.

What I expected

I expected the Portfolio Project to have the Tag I typed in.

What happened instead

The Tag I typed in was converted to a string of numbers.

Browser / OS version

Chrome Version 72.0.3626.119 (Official Build) (64-bit)
macOS Mojave version 10.14.3

Screenshot / Video

tag-numbers

Context / Source

user-report #manual-testing

Gutenberg WP REST API WPCOM API [Pri] High [Type] Bug

Most helpful comment

Fix by @mdawaffe is underway on D26092-code.

All 36 comments

I ran into this as well on 11032083-hc (1861597-zen), but for pages. I tested extensively and it happens on:

  • Gutenberg on Calypso (Gutenframe)
  • Gutenberg on wp-admin

It does not happen for pages created on:

  • The classic-editor on wp-admin
  • Calypso editor on Calypso

WordPress.com Business plan site used for all tests.

Google Chrome Version 72.0.3626.109 (Official Build) (64-bit) with macOS 10.14.2 - Mac OS Mojave, if that is important.

10938062-hc / cc @nagpai's report.

Just had a case myself in 11048610-hc

Another one reported here: 11147919-HC

In 1858292-zen: feedback that this bug is impacting SEO

I've got another one here: 7072281-HC

I did find another workaround:

  1. Remove featured tag from Customize > Featured Content.
  2. Add a tag to pages that should be featured in word form. So I added "featured" as the tag. That tag then gets converted to a number and should be the same on all pages.
  3. Note the number and add it to Customize > Featured Content.

That worked as a temporary workaround on this particular site.

Another reported here:

11191758-hc

Another one here: 8088196-hc

Another here: 11156634-hc

Initial report was in #1857763-zen

1880190-zen

User provided some step-by-step screenshots to reproduce.

Re-shared the workaround by @sstabrizi here #1858292-zen and closed until it gets fixed.

Another reported here: 11249841-hc

I tested this on my own site and also found that once it changes it to a number, it won't let me delete it.

I can recreate it by creating a new page as shown here: https://cld.wthms.co/I6VGFs

I have the Eris theme on a Premium site.

Another case here 1883377-zen. Shared the temporary workaround from above.

Another report in 1884795-zen.

Another report in 1885144-zen

Verified:

  • this isn't an issue with Classic
  • I can't replicate with posts
  • I _can_ replicate with Rebalance and Portfolios on dotcom
  • I _cannot_ replicate with Rebalance and Portfolios on a dotorg install (dotorg Rebalance doesn't seem to support tags on pages either?)

I think something's up with the POST API calls to https://public-api.wordpress.com/wp/v2/sites/:siteId/tags.

Tags like these are getting created, then faithfully brought back to the interface (as opposed to it being an issue all in the UI).

Screen Shot 2019-03-18 at 12 58 10 PM

Duplicate tags are being created with the name of the tag being the ID of the already-created tag.

  1. Add tag in the UI and hit Enter. The tag is added to the db via POST https://public-api.wordpress.com/wp/v2/sites/:siteId/tags?_envelope=1&_locale=user.
  2. Publish post. The ID of the above tag is included as form data in the call on publish to PUT https://public-api.wordpress.com/wp/v2/sites/:siteId/jetpack-portfolio/:postId?_envelope=1&_locale=user.

Screen Shot 2019-03-18 at 1 19 35 PM

Hm, maybe related complications and background: p7jreA-20e-p2.

Step 2 above (with the form data) looks like expected behaviour, since this is also how the working tags-on-posts performs. So the likely culprit is that PUT updates calling https://public-api.wordpress.com/wp/v2/sites/:siteId/jetpack-portfolio/postId (or maybe any CPT plus pages) are creating the tag[] value as a new name, rather than using them properly as tag IDs.

another issue on 9992877-HC

The problem could be the ID coming through as a string, at least it is when it gets to wp_set_post_terms.

Another issue: #11384762-hc

Another case of the same in 11408120-hc / 1894957-zen (for a page).

Another case of pages losing their tags and switching to numbers in 9921188-hc

Another report in 10172122-hc

+1 11455896-hc
Portfolio projects with Mellow theme

Another report.

Homepage tags - Heart And Style theme

11476631-hc

Another report:

1903240-zen

Another report in 1903510-zen

Another report: 1903794-zen

Confirmed it only happens on the Gutenberg editor. Replicated it with the "Caldwell" theme. I could only reproduce it with pages.

another: 9566559-hc

11597559-hc

Theme: Arcane
Happens on Pages.

When we enter even the same converted tag number from Calypso/iFramed Gutenberg, the number was turned to be another number again.

So it won't work at all there.

I edited the Page from WP Admin and it works just fine there.

Fix by @mdawaffe is underway on D26092-code.

Adding another report for posterity: https://fr.forums.wordpress.com/topic/probleme-etiquettes/

I believe this is now fixed. New updates to pages, portfolios, etc. should work correctly.

Was this page helpful?
0 / 5 - 0 ratings