Skip to content

DUPP-794-fix-deprecation-notice-in-block-editor#19346

Merged
leonidasmi merged 1 commit intotrunkfrom
DUPP-794-fix-deprecation-notice-in-block-editor
Dec 8, 2022
Merged

DUPP-794-fix-deprecation-notice-in-block-editor#19346
leonidasmi merged 1 commit intotrunkfrom
DUPP-794-fix-deprecation-notice-in-block-editor

Conversation

@pls78
Copy link
Copy Markdown
Member

@pls78 pls78 commented Dec 5, 2022

Context

  • We want to avoid a WordPress deprecation notice showing in the block editor.

Summary

This PR can be summarized in the following changelog entry:

  • Avoids a deprecation notice for the Yoast sidebar panel in the block editor.

Relevant technical choices:

Test instructions

Test instructions for the acceptance test before the PR gets merged

This PR can be acceptance tested by following these steps:

Without this PR

  • Install Yoast SEO
  • Open the browser's console
  • Open a post in the block editor:
    • Verify the following notice appears in the console:
select( 'core/edit-post' ).getPreferences is deprecated since version 6.0. Please use select( 'core/preferences' ).get instead.

With this PR

  • Install Yoast SEO
  • Open the browser's console
  • Open a post in the block editor:
    • Verify the notice is now gone
    • Verify also the Yoast SEO document panel is open in the sidebar
    • Verify the above both in a new installation and in a existing one

Screenshot 2022-12-05 at 15 55 50

Relevant test scenarios

  • Changes should be tested with the browser console open
  • Changes should be tested on different posts/pages/taxonomies/custom post types/custom taxonomies
  • Changes should be tested on different editors (Block/Classic/Elementor/other)
  • Changes should be tested on different browsers
  • Changes should be tested on multisite

Test instructions for QA when the code is in the RC

  • QA should use the same steps as above.

Impact check

This PR affects the following parts of the plugin, which may require extra testing:

  • Just the block editor is involved in this PR, specifically the check performed to determine if the Yoast panel in the sidebar has been opened for the first time after Yoast SEO is being installed. No other parts of the plugin should be tested.

UI changes

  • This PR changes the UI in the plugin. I have added the 'UI change' label to this PR.

Other environments

  • This PR also affects Shopify. I have added a changelog entry starting with [shopify-seo], added test instructions for Shopify and attached the Shopify label to this PR.

Documentation

  • I have written documentation for this change.

Quality assurance

  • I have tested this code to the best of my abilities
  • I have added unit tests to verify the code works as intended
  • If any part of the code is behind a feature flag, my test instructions also cover cases where the feature flag is switched off.
  • I have written this PR in accordance with my team's definition of done.

Innovation

  • No innovation project is applicable for this PR.
  • This PR falls under an innovation project. I have attached the innovation label and noted the work hours.

Fixes DUPP-794

@pls78 pls78 added the changelog: enhancement Needs to be included in the 'Enhancements' category in the changelog label Dec 5, 2022
@pls78 pls78 added this to the 19.13 milestone Dec 5, 2022
@leonidasmi leonidasmi marked this pull request as ready for review December 8, 2022 09:50
@leonidasmi
Copy link
Copy Markdown
Contributor

CR + Test is ✅

@leonidasmi leonidasmi merged commit 4d51702 into trunk Dec 8, 2022
@leonidasmi leonidasmi deleted the DUPP-794-fix-deprecation-notice-in-block-editor branch December 8, 2022 10:48
@enricobattocchi enricobattocchi modified the milestones: 19.13, 19.14 Dec 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog: enhancement Needs to be included in the 'Enhancements' category in the changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants