Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Please fix the following installer errors
- Install procedure validation failed for this plugin
- > User error in wp-content/plugins/wc-bayonet/wc-bayonet.php+34
Please update all AnsPress extensions before activating.
Server metrics [RAM: ▲0.03MB] [CPU: ▼7.60ms] Passed 4 tests
An overview of server-side resources used by WC Bayonet
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 25.04 ▼20.40 |
Dashboard /wp-admin | 3.35 ▲0.04 | 47.74 ▲0.76 |
Posts /wp-admin/edit.php | 3.46 ▲0.10 | 46.79 ▼3.09 |
Add New Post /wp-admin/post-new.php | 5.93 ▲0.04 | 85.94 ▼5.87 |
Media Library /wp-admin/upload.php | 3.27 ▲0.04 | 35.94 ▼1.02 |
Bayonet Settings /wp-admin/admin.php?page=bayonet_settings_page | 3.14 | 27.20 |
Server storage [IO: ▲0.69MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 142 new files
Database: no new tables, 7 new options
New WordPress options |
---|
theysaidso_admin_options |
recovery_mode_email_last_sent |
widget_recent-posts |
db_upgraded |
can_compress_scripts |
widget_theysaidso_widget |
widget_recent-comments |
Browser metrics Passed 4 tests
This is an overview of browser requirements for WC Bayonet
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,483 ▼252 | 13.21 ▼1.17 | 0.62 ▼1.43 | 17.58 ▼24.56 |
Dashboard /wp-admin | 2,221 ▲36 | 5.84 ▼0.05 | 103.34 ▼10.81 | 41.42 ▼0.77 |
Posts /wp-admin/edit.php | 2,107 ▲21 | 2.05 ▲0.06 | 35.64 ▼0.39 | 33.37 ▼4.87 |
Add New Post /wp-admin/post-new.php | 1,527 ▲13 | 17.73 ▲0.23 | 631.25 ▼46.47 | 73.23 ▲19.10 |
Media Library /wp-admin/upload.php | 1,400 ▲12 | 4.19 ▼0.02 | 96.19 ▼3.08 | 44.12 ▲0.18 |
Bayonet Settings /wp-admin/admin.php?page=bayonet_settings_page | 683 | 1.53 | 6.43 | 19.93 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
- The uninstall procedure has failed, leaving 7 options in the database
- widget_recent-comments
- widget_theysaidso_widget
- theysaidso_admin_options
- db_upgraded
- widget_recent-posts
- recovery_mode_email_last_sent
- can_compress_scripts
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Please fix the following server-side errors
- > GET request to /wp-admin/admin.php?page=bayonet_settings_page
- > User notice in wp-includes/functions.php+5905
Function WP_Scripts::localize was called incorrectly. The $l10n parameter must be an array. To pass arbitrary data to scripts, use the wp_add_inline_script() function instead. Please see Debugging in WordPress for more information. (This message was added in version 5.7.0.)
- > GET request to /wp-admin/admin.php?page=bayonet_settings_page
- > Error in wp-content/plugins/wc-bayonet/admin/partials/wc-bayonet-admin-settings-page.php+15
Uncaught Error: Call to undefined function wc_get_order_statuses() in wp-content/plugins/wc-bayonet/admin/partials/wc-bayonet-admin-settings-page.php:15
Stack trace:
#0 wp-content/plugins/wc-bayonet/admin/class-wc-bayonet-admin.php(125): require()
#1 wp-includes/class-wp-hook.php(310): WC_Bayonet_Admin->display_settings_page()
#2 wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
#3 wp-includes/plugin.php(517): WP_Hook->do_action()
#4 wp-admin/admin.php(259): do_action()
#5 {main}
thrown
SRP 50% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
- 46× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/promises/src/RejectedPromise.php:10
- > PHP Fatal error
Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/psr7/src/AppendStream.php:11
- > PHP Fatal error
Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/promises/src/Coroutine.php:43
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/wc-bayonet/includes/class-wc-bayonet.php:17
- > PHP Fatal error
Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/psr7/src/NoSeekStream.php:9
- > PHP Fatal error
Uncaught Error: Class 'GuzzleHttp\\Exception\\TransferException' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/guzzle/src/Exception/RequestException.php:12
- > PHP Fatal error
Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/psr7/src/PumpStream.php:16
- > PHP Fatal error
Uncaught Error: Class 'GuzzleHttp\\Exception\\BadResponseException' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/guzzle/src/Exception/ClientException.php:7
- > PHP Fatal error
Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/psr7/src/LimitStream.php:10
- > PHP Fatal error
Uncaught Error: Class 'GuzzleHttp\\Psr7\\Request' not found in wp-content/plugins/wc-bayonet/includes/src/guzzlehttp/psr7/src/ServerRequest.php:25
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention:
- Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line (
=== wc-bayonet ===
)
wc-bayonet/wc-bayonet.php 92% from 13 tests
The entry point to "WC Bayonet" version 1.0.0 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
- Description: Please keep the plugin description shorter than 140 characters (currently 166 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected12,863 lines of code in 128 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 104 | 1,760 | 5,320 | 8,866 |
Markdown | 10 | 939 | 0 | 3,274 |
JSON | 8 | 0 | 0 | 519 |
JavaScript | 2 | 16 | 68 | 99 |
PO File | 1 | 16 | 2 | 45 |
YAML | 1 | 7 | 0 | 34 |
CSS | 1 | 6 | 6 | 17 |
make | 1 | 4 | 0 | 9 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.41 |
Average class complexity | 12.76 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 72.00 |
Average method complexity | 2.58 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 27.00 |
Code structure | ||
---|---|---|
Namespaces | 9 | |
Interfaces | 14 | |
Traits | 2 | |
Classes | 72 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 72 | 100.00% |
▷ Final classes | 7 | 9.72% |
Methods | 687 | |
▷ Static methods | 80 | 11.64% |
▷ Public methods | 572 | 83.26% |
▷ Protected methods | 4 | 0.58% |
▷ Private methods | 111 | 16.16% |
Functions | 149 | |
▷ Named functions | 57 | 38.26% |
▷ Anonymous functions | 92 | 61.74% |
Constants | 47 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 47 | 100.00% |
▷ Public constants | 47 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There were not PNG files found in your plugin