wordpress-mobile / wordpress-mobile/WordPress-Android

YouTube shortcode not rendering correctly in notification mention

Open
#12,800 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

[Pri] Low [Type] Bug Comments Notifications Reader
Dominant language
Kotlin
Stars
3.2k
Forks
1.4k
Avg merge
1d 11h
Merged PRs (30d)
69

Description

Expected behavior

When viewed via the Notifications tab in WPAndroid, a comment that includes a Shortcode block which in-turn contains the YouTube shortcode (e.g. [youtube https://www.youtube.com/watch?v=fX8YLri4wxU]) should be rendered correctly (i.e. the YouTube video should be visible in the comment). Note: this works fine for posts that contain this same content.

Actual behavior

The raw shortcode itself is visible instead of the referenced YouTube video.

Post notification — works here ✅ Comment notification — doesn't work here ❌
Screenshot showing YouTube shortcode rendering correctly in post notification in WPAndroid Screenshot showing YouTube shortcode rendering incorrectly in comment notification in WPAndroid
Steps to reproduce the behavior
  1. On the web, log into a WordPress site that has Gutenberg enabled in comments (e.g. create a site on http://wp.com/p2)
  2. Add another WordPress user, granting the Administrator role (other roles may work)
  3. Still on the same site, create a reply (comment) to a post, @-mentioning the newly added user
  4. Add an Shortcode block to that same reply (sample content [youtube https://www.youtube.com/watch?v=fX8YLri4wxU])
  5. Send the reply
  6. From the WPAndroid app, log in as the newly added Administrator
  7. In the Notifications tab, locate the notification for the reply that @-mentioned the user
  8. Open the comment, and notice the video is not visible — only the raw shortcode is visible
Tested on Samsung S10, Android 10, WPAndroid 15.4.1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue in the WPAndroid Notifications tab using a comment with a Shortcode block containing the shown YouTube shortcode, then compare it with the working post notification behavior. Done means the comment notification renders the YouTube video instead of displaying the raw shortcode.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, kotlin
Domain
mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.