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

Remove 4.3 deprecated APIs #11679

Merged
merged 5 commits into from
Nov 9, 2018
Merged

Conversation

youknowriad
Copy link
Contributor

No description provided.

@youknowriad youknowriad added this to the 4.3 milestone Nov 9, 2018
@youknowriad youknowriad self-assigned this Nov 9, 2018
@youknowriad youknowriad requested a review from a team November 9, 2018 16:10
Copy link
Member

@tofumatt tofumatt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm curious about removing @wordpress/deprecated from the code. Won't we want to continue using it?

@@ -2479,7 +2479,6 @@
"@wordpress/compose": "file:packages/compose",
"@wordpress/core-data": "file:packages/core-data",
"@wordpress/data": "file:packages/data",
"@wordpress/deprecated": "file:packages/deprecated",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😱 is that correct?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(I think we added a deprecation in #11543, fwiw.)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is correct in that the current state of master after this branch would have no occurrence of @wordpress/deprecated in edit-post.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's correct as the edit-post package don't have any other deprecations anymore.

Ideally, we don't add more deprecations now as we're in API Freeze and keep supporting both APIs unless we think it's very unlikely that someone is using the said API in which I case you can add the dependency back in the PR.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But we could have API changes post-5.0, right? I assumed we'd still want to be able to deprecate APIs after the core merge.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tofumatt yes, but the process is not defined yet.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The dependencies should only be those which are actively used. If we need to deprecate in the future, it can be brought back.

/**
* WordPress dependencies
*/
import deprecated from '@wordpress/deprecated';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The module is mocked in test/selectors.js which should be removed as well.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The module is mocked in test/selectors.js which should be removed as well.

Aside: While I like this pattern of mocking @wordpress/deprecated, it's certainly hard to discover in these removals.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, also it doesn't seem like it was useful here as the tests were passing anyway.

@@ -2479,7 +2479,6 @@
"@wordpress/compose": "file:packages/compose",
"@wordpress/core-data": "file:packages/core-data",
"@wordpress/data": "file:packages/data",
"@wordpress/deprecated": "file:packages/deprecated",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is correct in that the current state of master after this branch would have no occurrence of @wordpress/deprecated in edit-post.

@youknowriad youknowriad merged commit 004d731 into master Nov 9, 2018
@youknowriad youknowriad deleted the update/remove-deprecated-apis-43 branch November 9, 2018 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants