Prevent method names from being emitted as global WP functions in since-data generation#1276
Conversation
Agent-Logs-Url: https://github.com/WordPress/plugin-check/sessions/f6a71ac5-4f70-4286-b4ff-7d78d37ba31d Co-authored-by: ernilambar <2098823+ernilambar@users.noreply.github.com>
Agent-Logs-Url: https://github.com/WordPress/plugin-check/sessions/f6a71ac5-4f70-4286-b4ff-7d78d37ba31d Co-authored-by: ernilambar <2098823+ernilambar@users.noreply.github.com>
|
@copilot run the modified generator script for new json and include it in the same pull request. |
Agent-Logs-Url: https://github.com/WordPress/plugin-check/sessions/f8d70e19-6057-4c3e-96a8-b8a832f61948 Co-authored-by: ernilambar <2098823+ernilambar@users.noreply.github.com>
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Unlinked AccountsThe following contributors have not linked their GitHub and WordPress.org accounts: @Copilot. Contributors, please read how to link your accounts to ensure your work is properly credited in WordPress releases. If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
wp_functions_compatibilitywas flagging PHPserialize()as a WordPress function introduced in 6.7 because the generatedwp-functions-since.jsonincorrectly included a class method (WP_HTML_Processor::serialize) as a global function. This change tightens dataset generation so only true global functions are emitted.Generator parsing fix
tools/generate-wp-function-since-data.phpbrace/class-scope tracking to correctly stay inside class context even when token streams include curly-interpolation tokens.function_since.Dataset correction
includes/Vars/wp-functions-since.json."serialize": "6.7.0"entry and refreshes the full dataset based on the fixed generation logic (including metadata/version updates from the regenerated source).Regression coverage
serialize()and a PHPUnit assertion inWP_Functions_Compatibility_Check_Testsconfirming nowp_function_not_compatible_with_requires_wperror is reported for that usage.> [!WARNING]
>
>