Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
You still need to fix the following installer errors
- This plugin did not install gracefully
- > Error in wp-content/plugins/a2z-canada-post-automated-shipping/hit_canadapost_auto_basic.php+42
Uncaught Error: Call to undefined function WC() in wp-content/plugins/a2z-canada-post-automated-shipping/hit_canadapost_auto_basic.php:42
Stack trace:
#0 wp-includes/class-wp-hook.php(312): hit_woo_cp_plugin_activation()
#1 wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
#2 wp-includes/plugin.php(517): WP_Hook->do_action()
#3 wp-admin/includes/plugin.php(720): do_action()
Server metrics [RAM: ▲0.12MB] [CPU: ▼6.03ms] Passed 4 tests
A check of server-side resources used by Automated Canada Post - HPOS Supported
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.58 ▲0.12 | 36.03 ▼10.13 |
Dashboard /wp-admin | 3.43 ▲0.12 | 46.80 ▼4.50 |
Posts /wp-admin/edit.php | 3.48 ▲0.12 | 47.48 ▼0.34 |
Add New Post /wp-admin/post-new.php | 6.01 ▲0.12 | 82.30 ▼9.14 |
Media Library /wp-admin/upload.php | 3.35 ▲0.12 | 35.44 ▼0.32 |
Server storage [IO: ▲0.48MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 25 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
widget_recent-comments |
db_upgraded |
theysaidso_admin_options |
can_compress_scripts |
widget_recent-posts |
Browser metrics Passed 4 tests
A check of browser resources used by Automated Canada Post - HPOS Supported
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,789 ▲3 | 14.15 ▼0.47 | 1.57 ▼0.34 | 39.16 ▼6.98 |
Dashboard /wp-admin | 2,192 ▲15 | 5.54 ▼0.04 | 88.05 ▼6.59 | 38.63 ▼5.39 |
Posts /wp-admin/edit.php | 2,100 ▼0 | 1.97 ▲0.02 | 38.82 ▲2.17 | 38.30 ▲2.72 |
Add New Post /wp-admin/post-new.php | 1,526 ▼0 | 23.14 ▼0.02 | 659.15 ▲5.03 | 62.67 ▲6.82 |
Media Library /wp-admin/upload.php | 1,394 ▼0 | 4.35 ▲0.17 | 94.60 ▼2.41 | 40.71 ▼2.07 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
- Zombie WordPress options detected upon uninstall: 6 options
- widget_recent-posts
- widget_theysaidso_widget
- widget_recent-comments
- theysaidso_admin_options
- can_compress_scripts
- db_upgraded
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
- 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Class 'WeightPackStrategy' not found in wp-content/plugins/a2z-canada-post-automated-shipping/controllors/classes/weight_pack/class-hit-weight-strategy-descend.php:28
- > PHP Fatal error
Uncaught Error: Class 'WeightPackStrategy' not found in wp-content/plugins/a2z-canada-post-automated-shipping/controllors/classes/weight_pack/class-hit-weight-strategy-simple.php:28
- > PHP Fatal error
Uncaught Error: Class 'WeightPackStrategy' not found in wp-content/plugins/a2z-canada-post-automated-shipping/controllors/classes/weight_pack/class-hit-weight-strategy-ascend.php:28
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found
Optimizations
Plugin configuration 90% from 29 tests
readme.txt Passed 16 tests
You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
5 plugin tags: canada post woocommerce, canada post plugin, canada post, canada post shipping, canada post shipping method
a2z-canada-post-automated-shipping/hit_canadapost_auto_basic.php 77% from 13 tests
The principal PHP file in "Automated Canada Post - HPOS Supported" v. 2.4.0 is loaded by WordPress automatically on each request
You should first fix the following items:
- Requires at least: The required version number did not match the one declared in readme.txt ("4.0.1" instead of "2.6")
- Text Domain: Please use dashes and lowercase characters for text domains
- Main file name: It is recommended to name the main PHP file as the plugin slug ("a2z-canada-post-automated-shipping.php" instead of "hit_canadapost_auto_basic.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin3,604 lines of code in 16 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 11 | 433 | 674 | 3,490 |
XML | 5 | 1 | 0 | 114 |
PHP code Passed 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.38 |
Average class complexity | 28.67 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 146.00 |
Average method complexity | 4.42 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 48.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 12 | |
▷ Abstract classes | 1 | 8.33% |
▷ Concrete classes | 11 | 91.67% |
▷ Final classes | 0 | 0.00% |
Methods | 98 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 89 | 90.82% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 9 | 9.18% |
Functions | 2 | |
▷ Named functions | 1 | 50.00% |
▷ Anonymous functions | 1 | 50.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.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
2 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
controllors/views/hcp.png | 7.95KB | 3.74KB | ▼ 52.91% |
controllors/views/cp_logo.png | 25.41KB | 25.40KB | 0.05% |