Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲0.26MB] [CPU: ▼0.03ms] Passed 4 tests
Analyzing server-side resources used by Shipping Method for UPS and WooCommerce
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.71 ▲0.25 | 42.57 ▲0.82 |
Dashboard /wp-admin | 3.61 ▲0.30 | 49.66 ▼0.30 |
Posts /wp-admin/edit.php | 3.66 ▲0.30 | 49.90 ▲1.16 |
Add New Post /wp-admin/post-new.php | 6.12 ▲0.24 | 85.73 ▼1.79 |
Media Library /wp-admin/upload.php | 3.47 ▲0.24 | 38.29 ▲2.80 |
Server storage [IO: ▲4.81MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 467 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
theysaidso_admin_options |
widget_theysaidso_widget |
widget_recent-comments |
widget_recent-posts |
can_compress_scripts |
Browser metrics Passed 4 tests
Shipping Method for UPS and WooCommerce: an overview of browser usage
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,789 ▲28 | 14.27 ▼0.11 | 1.81 ▲0.24 | 41.05 ▼0.07 |
Dashboard /wp-admin | 2,195 ▲31 | 5.62 ▼0.04 | 89.58 ▼7.27 | 41.34 ▲6.48 |
Posts /wp-admin/edit.php | 2,100 ▼0 | 2.01 ▼0.03 | 39.57 ▼0.86 | 36.03 ▼1.26 |
Add New Post /wp-admin/post-new.php | 1,528 ▲2 | 23.25 ▼0.36 | 650.10 ▼59.56 | 51.89 ▼3.88 |
Media Library /wp-admin/upload.php | 1,403 ▲6 | 4.26 ▲0.11 | 93.14 ▼8.84 | 43.61 ▼3.91 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
- This plugin does not fully uninstall, leaving 6 options in the database
- widget_recent-comments
- widget_recent-posts
- theysaidso_admin_options
- widget_theysaidso_widget
- can_compress_scripts
- db_upgraded
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
- 182× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'WPRuby_UPS_Libs\\Ups\\Entity\\ShipTo' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/gabrielbull/ups-api/src/Entity/AlternateDeliveryAddress.php:7
- > PHP Fatal error
Uncaught Error: Interface 'WPRuby_UPS_Libs\\GuzzleHttp\\Exception\\GuzzleException' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/guzzlehttp/guzzle/src/Exception/TransferException.php:5
- > PHP Fatal error
Uncaught Error: Class 'WPRuby_UPS_Libs\\DVDoug\\BoxPacker\\Packer' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/dvdoug/boxpacker/src/InfalliblePacker.php:16
- > PHP Fatal error
Uncaught Error: Class 'WPRuby_UPS_Libs\\GuzzleHttp\\Cookie\\CookieJar' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php:10
- > PHP Fatal error
Uncaught Error: Interface 'WPRuby_UPS_Libs\\DVDoug\\BoxPacker\\Item' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/dvdoug/boxpacker/src/ConstrainedPlacementItem.php:17
- > PHP Fatal error
Uncaught Error: Interface 'WPRuby_UPS_Libs\\GuzzleHttp\\Promise\\PromisorInterface' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/guzzlehttp/promises/src/EachPromise.php:9
- > PHP Fatal error
Uncaught Error: Interface 'WPRuby_UPS_Libs\\Psr\\Http\\Message\\UploadedFileInterface' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/guzzlehttp/psr7/src/UploadedFile.php:10
- > PHP Fatal error
Uncaught Error: Class 'WPRuby_UPS_Libs\\GuzzleHttp\\Exception\\RequestException' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php:11
- > PHP Fatal error
Uncaught Error: Interface 'WPRuby_UPS_Libs\\Ups\odeInterface' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/gabrielbull/ups-api/src/Entity/UnitOfMeasurement.php:9
- > PHP Fatal error
Uncaught Error: Interface 'WPRuby_UPS_Libs\\Ups\odeInterface' not found in wp-content/plugins/shipping-method-for-ups-and-wc/vendor/gabrielbull/ups-api/src/Entity/Tradeability/Weight.php:12
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side
Optimizations
Plugin configuration 90% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
7 plugin tags: ups, ups shipping, ups api, woocommerce extension, woocommerce...
shipping-method-for-ups-and-wc/ups-shipping-method.php 77% from 13 tests
"Shipping Method for UPS and WooCommerce" version 1.0.3's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
- Requires at least: Required version does not match the one declared in readme.txt ("4.0" instead of "3.0")
- Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
- Main file name: The principal plugin file should be the same as the plugin slug ("shipping-method-for-ups-and-wc.php" instead of "ups-shipping-method.php")
Code Analysis 5% from 3 tests
File types 0% from 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
These items require your attention
- You should never include executable (binary) or otherwise dangerous files in your plugin
- .ps1 - Windows PowerShell Cmdlet in Windows
- ☣ wp-content/plugins/shipping-method-for-ups-and-wc/vendor/dvdoug/boxpacker/docs/build.ps1
- .ps1 - Windows PowerShell Cmdlet in Windows
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 359 | 6,166 | 14,390 | 26,023 |
Markdown | 17 | 1,412 | 0 | 4,303 |
JSON | 12 | 0 | 0 | 1,312 |
YAML | 7 | 60 | 3 | 300 |
XSD | 6 | 0 | 0 | 277 |
reStructuredText | 8 | 132 | 260 | 178 |
Cucumber | 3 | 22 | 0 | 165 |
Python | 1 | 39 | 92 | 40 |
XML | 5 | 5 | 1 | 30 |
make | 2 | 8 | 6 | 19 |
Dockerfile | 1 | 1 | 0 | 2 |
PowerShell | 1 | 0 | 0 | 2 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.28 |
Average class complexity | 8.62 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 108.00 |
Average method complexity | 2.12 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 72.00 |
Code structure | ||
---|---|---|
Namespaces | 28 | |
Interfaces | 36 | |
Traits | 7 | |
Classes | 298 | |
▷ Abstract classes | 3 | 1.01% |
▷ Concrete classes | 295 | 98.99% |
▷ Final classes | 20 | 6.78% |
Methods | 2,290 | |
▷ Static methods | 170 | 7.42% |
▷ Public methods | 2,081 | 90.87% |
▷ Protected methods | 21 | 0.92% |
▷ Private methods | 188 | 8.21% |
Functions | 170 | |
▷ Named functions | 55 | 32.35% |
▷ Anonymous functions | 115 | 67.65% |
Constants | 422 | |
▷ Global constants | 1 | 0.24% |
▷ Class constants | 421 | 99.76% |
▷ Public constants | 420 | 99.76% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
3 PNG files occupy 0.21MB with 0.15MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/screenshot-3.png | 65.50KB | 18.12KB | ▼ 72.34% |
assets/screenshot-2.png | 90.53KB | 27.28KB | ▼ 69.87% |
assets/screenshot-1.png | 60.96KB | 18.31KB | ▼ 69.97% |