Benchmarks
Plugin footprint 64% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully
Server metrics [RAM: ▲5.84MB] [CPU: ▲35.85ms] 50% from 4 tests
Analyzing server-side resources used by Knowledge Base documentation & wiki plugin - BasePress Docs
The following require your attention
- RAM: You should keep total memory usage under 10MB (currently 11.58MB on /wp-admin/post-new.php?post_type=knowledgebase)
- Extra RAM: The extra memory usage should kept under 5MB (currently 5.84MB on /wp-admin/edit.php?post_type=knowledgebase&page=basepress_manage_kbs)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 9.25 ▲5.79 | 69.83 ▲28.54 |
Dashboard /wp-admin | 9.27 ▲5.97 | 82.75 ▲34.72 |
Posts /wp-admin/edit.php | 9.27 ▲5.91 | 94.49 ▲46.05 |
Add New Post /wp-admin/post-new.php | 11.56 ▲5.67 | 131.97 ▲41.52 |
Media Library /wp-admin/upload.php | 9.27 ▲6.04 | 71.55 ▲38.60 |
Add New Article /wp-admin/post-new.php?post_type=knowledgebase | 11.58 | 124.11 |
All Articles /wp-admin/edit.php?post_type=knowledgebase | 9.27 | 87.87 |
Setup Wizard /wp-admin/admin.php?page=basepress_wizard | 9.27 | 64.41 |
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius | 9.27 | 67.59 |
Sections /wp-admin/edit.php?post_type=knowledgebase&page=basepress_sections | 9.27 | 72.97 |
Manage KBs /wp-admin/edit.php?post_type=knowledgebase&page=basepress_manage_kbs | 9.27 | 79.97 |
Server storage [IO: ▲5.65MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 370 new files
Database: no new tables, 19 new options
New WordPress options |
---|
widget_basepress_sections_widget |
fs_active_plugins |
widget_basepress_products_widget |
widget_basepress_related_articles_widget |
basepress_plan |
knowledgebase_cat_children |
widget_basepress_nav_widget |
basepress_settings |
basepress_db_ver |
widget_recent-posts |
... |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Knowledge Base documentation & wiki plugin - BasePress Docs
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,888 ▲126 | 14.30 ▼0.39 | 1.57 ▼0.23 | 28.48 ▼15.28 |
Dashboard /wp-admin | 2,287 ▲109 | 5.55 ▼0.08 | 98.55 ▼16.09 | 48.44 ▲4.01 |
Posts /wp-admin/edit.php | 2,196 ▲96 | 2.16 ▲0.13 | 39.46 ▲2.21 | 38.69 ▼0.40 |
Add New Post /wp-admin/post-new.php | 6,427 ▲4,898 | 27.66 ▲4.07 | 892.34 ▲283.34 | 39.37 ▼17.12 |
Media Library /wp-admin/upload.php | 1,496 ▲96 | 4.14 ▼0.01 | 97.04 ▼0.35 | 44.88 ▲2.76 |
Add New Article /wp-admin/post-new.php?post_type=knowledgebase | 2,260 | 16.88 | 851.98 | 54.96 |
All Articles /wp-admin/edit.php?post_type=knowledgebase | 1,307 | 2.10 | 40.57 | 35.95 |
Setup Wizard /wp-admin/admin.php?page=basepress_wizard | 1,123 | 2.04 | 29.27 | 48.17 |
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius | 1,138 | 1.66 | 24.64 | 27.29 |
Sections /wp-admin/edit.php?post_type=knowledgebase&page=basepress_sections | 1,716 | 3.48 | 64.17 | 36.12 |
Manage KBs /wp-admin/edit.php?post_type=knowledgebase&page=basepress_manage_kbs | 1,410 | 3.22 | 41.68 | 29.44 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
- Uninstall procedure had uncaught errors
- > Notice in wp-content/plugins/basepress/freemius/includes/class-freemius.php+8486
Undefined property: stdClass::$plugins
- The uninstall procedure has failed, leaving 19 options in the database
- fs_active_plugins
- widget_basepress_related_articles_widget
- basepress_run_wizard
- widget_recent-comments
- basepress_settings
- widget_basepress_products_widget
- knowledgebase_cat_children
- widget_basepress_sections_widget
- can_compress_scripts
- widget_theysaidso_widget
- ...
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting 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 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
- 60× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_kb() in wp-content/plugins/basepress/themes/zen/tag.php:8
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_kb() in wp-content/plugins/basepress/themes/default/sections-boxed.php:8
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_sidebar_position() in wp-content/plugins/basepress/themes/default/restricted.php:6
- > PHP Fatal error
Uncaught Error: Call to undefined function the_ID() in wp-content/plugins/basepress/themes/default/template-parts/post-content.php:7
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_kb() in wp-content/plugins/basepress/themes/default/sections.php:8
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_kb() in wp-content/plugins/basepress/themes/default/two-columns-left.php:5
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_kbs() in wp-content/plugins/basepress/themes/modern/products.php:9
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_sections() in wp-content/plugins/basepress/themes/modern/template-parts/single-section-content.php:8
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_sections() in wp-content/plugins/basepress/themes/zen/template-parts/sections-content.php:9
- > PHP Fatal error
Uncaught Error: Call to undefined function basepress_kb() in wp-content/plugins/basepress/themes/zen/restricted.php:7
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 88% from 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need to be fixed:
- Screenshots: Please add descriptions for these screenshots #4, #5, #6, #7, #8, #9 in basepress/assets to your readme.txt
- Tags: Please delete some tags, you are using 14 tag instead of maximum 10
basepress/basepress.php Passed 13 tests
The main PHP file in "Knowledge Base documentation & wiki plugin - BasePress Docs" ver. 2.15.24 adds more information about the plugin and also serves as the entry point for this plugin
47 characters long description:
The perfect Knowledge Base plugin for WordPress
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin60,010 lines of code in 284 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 214 | 10,909 | 20,746 | 44,674 |
CSS | 22 | 1,266 | 369 | 7,869 |
PO File | 3 | 1,654 | 2,385 | 3,383 |
JavaScript | 27 | 615 | 397 | 2,693 |
SVG | 1 | 0 | 0 | 685 |
XML | 2 | 11 | 1 | 396 |
JSON | 11 | 0 | 0 | 224 |
HTML | 4 | 6 | 0 | 86 |
PHP code 50% from 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
These items need your attention
- Class cyclomatic complexity has to be reduced to less than 1000 (currently 3,073)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.55 |
Average class complexity | 69.51 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 3,073.00 |
Average method complexity | 4.59 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 94.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 83 | |
▷ Abstract classes | 2 | 2.41% |
▷ Concrete classes | 81 | 97.59% |
▷ Final classes | 0 | 0.00% |
Methods | 1,601 | |
▷ Static methods | 199 | 12.43% |
▷ Public methods | 1,173 | 73.27% |
▷ Protected methods | 17 | 1.06% |
▷ Private methods | 411 | 25.67% |
Functions | 174 | |
▷ Named functions | 166 | 95.40% |
▷ Anonymous functions | 8 | 4.60% |
Constants | 155 | |
▷ Global constants | 108 | 69.68% |
▷ Class constants | 47 | 30.32% |
▷ Public constants | 47 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
8 PNG files occupy 0.04MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
freemius/assets/img/theme-icon.png | 10.97KB | 5.78KB | ▼ 47.37% |
themes/zen/img/plus-circle.png | 3.30KB | 1.88KB | ▼ 42.95% |
assets/img/wizard-header.png | 6.94KB | 4.04KB | ▼ 41.85% |
assets/img/logo.png | 0.87KB | 0.79KB | ▼ 8.99% |
freemius/assets/img/plugin-icon.png | 9.16KB | 5.26KB | ▼ 42.58% |