#63168 closed task (blessed) (fixed)
Coding Standards fixes for WP 6.9
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | 6.9 | Priority: | normal |
| Severity: | normal | Version: | |
| Component: | General | Keywords: | has-patch has-unit-tests changes-requested |
| Focuses: | coding-standards | Cc: |
Attachments (1)
Change History (73)
#7
@
8 months ago
Hello
I've submitted a PHPCS-related patch on Below ticket.
Ticket : https://core.trac.wordpress.org/ticket/63351
Kindly also take a moment to review this ticket
Thank you
This ticket was mentioned in Slack in #core by joemcgill. View the logs.
7 months ago
#11
@
6 months ago
- Resolution set to invalid
- Status changed from new to closed
#45939: One <br /> left.
This ticket was mentioned in PR #10076 on WordPress/wordpress-develop by @paulbonneau.
3 months ago
#18
- Keywords has-patch added
Format corrections in this commit is the produce of executing the composer format command of wordpress-develop (/composer.json > scripts > format) on the wordpress-develop codebase.
@SergeyBiryukov commented on PR #10076:
3 months ago
#20
Thanks for the PR! Merged in r60808.
This ticket was mentioned in PR #10111 on WordPress/wordpress-develop by @mukesh27.
2 months ago
#21
- Keywords has-unit-tests added
Trac ticket: https://core.trac.wordpress.org/ticket/63168
This PR makes minor improvements to the documentation in the test suite for comment template rendering. Specifically, it adds a blank line between the @ticket and @covers annotations in several test methods, also correct indentation for inline comment.
@SergeyBiryukov commented on PR #10111:
2 months ago
#22
Thanks for the PR! Merged in r60889.
This ticket was mentioned in PR #10147 on WordPress/wordpress-develop by @mukesh27.
2 months ago
#23
Trac ticket: https://core.trac.wordpress.org/ticket/63168
This ticket was mentioned in PR #10221 on WordPress/wordpress-develop by @peterwilsoncc.
2 months ago
#27
Renames the variables used for local instances of $this->query_vars in WP_Query.
The local references currently use the abbreviations $q or $qv rather than a meaningful name, this changes the local references to $query_vars` for consistency and clarity/self documenting.
Trac ticket: https://core.trac.wordpress.org/ticket/63168
This ticket was mentioned in PR #10221 on WordPress/wordpress-develop by @peterwilsoncc.
2 months ago
#28
Renames the variables used for local instances of $this->query_vars in WP_Query.
The local references currently use the abbreviations $q or $qv rather than a meaningful name, this changes the local references to $query_vars` for consistency and clarity/self documenting.
Trac ticket: https://core.trac.wordpress.org/ticket/63168
@peterwilsoncc commented on PR #10221:
2 months ago
#30
#32
in reply to:
↑ 26
@
2 months ago
- Keywords changes-requested added
Replying to SergeyBiryukov:
In 60924:
The $s global is still being used elsewhere:
$ ack 'global(\s|.+?, )\$s(,|;)' src/wp-admin/ src/wp-admin/includes/class-wp-ms-sites-list-table.php 69: global $mode, $s, $wpdb; src/wp-admin/includes/class-wp-links-list-table.php 51: global $cat_id, $s, $orderby, $order; src/wp-admin/includes/class-wp-ms-themes-list-table.php 100: global $status, $totals, $page, $orderby, $order, $s; 548: global $status, $page, $s; src/wp-admin/includes/class-wp-plugins-list-table.php 91: global $status, $plugins, $totals, $page, $orderby, $order, $s; 375: global $s; 724: global $status, $page, $s, $totals
On /wp-admin/plugins.php, for example, there is currently an error (as noted by @mukesh27 in Slack):
Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /var/www/src/wp-admin/includes/class-wp-plugins-list-table.php on line 297
Many more replacements would be needed, for example search_term_global.diff
I worry about back-comapt problems for this change, however. There are close to two hundred plugins that are looking at the $s global: https://wpdirectory.net/search/01K7FVTRKDN6DTVNK82CYK72ZB
I think [60924] needs to be reverted.
This ticket was mentioned in Slack in #core by westonruter. View the logs.
2 months ago
This ticket was mentioned in PR #3189 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#37
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
This ticket was mentioned in PR #3190 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#38
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
This ticket was mentioned in PR #3191 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#39
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
This PR includes renaming of the following variables:
$sbnameto$sidebar_name.$sbvalueto$sidebar_data.$jto$widget_count.$ito$sidebar_index.$sbto$sidebar.$keyto$sidebar_id.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
This ticket was mentioned in PR #3192 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#40
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
This PR includes renaming of the following variables:
$ito$submenu_index.$capto$capability.$taxto$taxonomy.- Several
$awaiting_mod_*to$awaiting_moderation_*. - Several
$ptype_*to$post_type_*. $typesto$post_types.$appearance_capto$appearance_capability.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
This ticket was mentioned in PR #3193 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#41
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
This PR includes renaming of the following variables:
$rto$edit_result.$extto$extension.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
This ticket was mentioned in PR #3194 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#42
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
This PR includes renaming of the following variables:
$qto$query_string.$varsto$query_vars.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
This ticket was mentioned in PR #3195 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#43
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
This PR includes renaming of the following variables:
$hto$header.
Not touched:
$oitar- This is$ratiobackwards. Props @SergeyBiryukov.- This is also used as a hidden form field's name.
- Not touched by this PR. If there's a desire to change it, let's change it on its own after auditing for BC.
There are a couple of variables I'd like some input on:
$dst_height- This could be$dest_height, but that doesn't seem like a worthwhile change. Suggestions?$dst_width- See above.- Edit Feedback received. No change to these.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
This ticket was mentioned in PR #3197 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#44
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
This PR includes renaming of the following variables:
$rto$upgrade_data.$resto$connected.$pluginfilesto$plugin_files- Per naming conventions, separate words via underscores.$infoto$new_plugin_data.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
This ticket was mentioned in PR #3198 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#45
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
This PR includes renaming of the following variables:
$post_IDto$post_id. - "Use lowercase letters in variable, action/filter, and function names"$ext_typeto$extension_type.$extto$extension.$id3datato$id3_data. - "Separate words via underscores."$msgto$message.$sbto$sidebar.$altto$alternate.$pidto$post_id.$menu_objto$menu_object.$noparentsto$no_parents. - "Separate words via underscores."$supto$supplemental.$cat_idto$category_id.$cat_nameto$category_name.$outto$output.$rto$edit_result.$tto$taxonomy.$uto$update_result.$rto$result.$responseto$response_data.$xto$response.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
@SergeyBiryukov commented on PR #3195:
8 weeks ago
#47
Thanks for the PR! Merged in r60970.
This ticket was mentioned in PR #3196 on WordPress/wordpress-develop by @costdev.
8 weeks ago
#48
Per naming conventions, don’t abbreviate variable names unnecessarily; let the code be unambiguous and self-documenting.
See PHP Coding Standards - Naming Conventions.
This PR includes renaming of the following variables:
$rto$upgrade_data.$resto$connected.$infoto$new_theme_data.
Trac ticket:
https://core.trac.wordpress.org/ticket/63168
https://core.trac.wordpress.org/ticket/55647
@SergeyBiryukov commented on PR #3197:
8 weeks ago
#53
Thanks for the PR! Merged in r60997.
@SergeyBiryukov commented on PR #3196:
8 weeks ago
#54
Thanks for the PR! Merged in r61028.
This ticket was mentioned in PR #10378 on WordPress/wordpress-develop by @jorbin.
8 weeks ago
#55
Introduced in 60939
Trac ticket: https://core.trac.wordpress.org/ticket/63168
This ticket was mentioned in PR #10379 on WordPress/wordpress-develop by @jorbin.
8 weeks ago
#56
Trac ticket: https://core.trac.wordpress.org/ticket/63168
@jorbin commented on PR #10379:
7 weeks ago
#60
Committed in 61036
@jorbin commented on PR #10378:
7 weeks ago
#61
Committed in 61035
This ticket was mentioned in PR #10467 on WordPress/wordpress-develop by @jorbin.
6 weeks ago
#64
Add all the commits made during 6.9 that are blank space only commits.
Trac ticket: https://core.trac.wordpress.org/ticket/63168
@jorbin commented on PR #10467:
5 weeks ago
#66
Thanks @peterwilsoncc!
This was committed in https://core.trac.wordpress.org/changeset/61143
@SergeyBiryukov commented on PR #3191:
5 weeks ago
#68
Thanks for the PR! Merged in r61187.
#69
@
5 weeks ago
- Resolution set to fixed
- Status changed from reopened to closed
With RC1 in less than 24 hours and the branching of 6.9 immanent, I've created #64226 for the 7.0 release and will close this one out.
If there are further changes required for 6.9, this can be reopened or referenced in the commit message.
@SergeyBiryukov commented on PR #3192:
4 weeks ago
#71
Thanks for the PR! Merged in r61200.
@SergeyBiryukov commented on PR #3198:
4 weeks ago
#72
Thanks for the PR! Merged in r61224.
In 60094: