84% bot-libre-chatbot

Code Review | Bot Libre Chatbot

WordPress plugin Bot Libre Chatbot scored 84% from 54 tests.

About plugin

  • Plugin page: bot-libre-chatbot
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress version: 5.8.1
  • First release: Feb 15, 2018
  • Latest release: Nov 6, 2018
  • Number of updates: 4
  • Update frequency: every 66.0 days
  • Top authors: paphus (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 841 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.05MB] [CPU: ▼142.24ms] Passed 4 tests

Analyzing server-side resources used by Bot Libre Chatbot
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.89 ▲0.1734.87 ▲12.93
Dashboard /wp-admin3.12 ▲0.0648.75 ▲3.49
Posts /wp-admin/edit.php3.17 ▲0.0647.59 ▲2.11
Add New Post /wp-admin/post-new.php5.47 ▲0.0491.37 ▼570.21
Media Library /wp-admin/upload.php3.06 ▲0.0631.10 ▼4.36

Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 2 new files
Database: no new tables, 1 new option
New WordPress options
widget_bot_libre_widget

Browser metrics Passed 4 tests

Checking browser requirements for Bot Libre Chatbot
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,679 ▲8315.81 ▲0.468.70 ▼2.6846.91 ▼4.84
Dashboard /wp-admin2,973 ▲395.93 ▼0.30148.43 ▼24.65112.16 ▲1.16
Posts /wp-admin/edit.php2,739 ▼02.72 ▼0.0067.23 ▼1.1187.55 ▼5.21
Add New Post /wp-admin/post-new.php1,683 ▲6818.72 ▼2.74398.30 ▲91.85109.77 ▼0.30
Media Library /wp-admin/upload.php1,807 ▼35.03 ▼0.01157.89 ▲1.92110.26 ▼2.55

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 1 option in the database
    • widget_bot_libre_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/bot-libre-chatbot/embed_bot_widget.php:11

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 errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that need to be fixed:
  • Contributors: Contributors not specified
Please take inspiration from this readme.txt

bot-libre-chatbot/embed_bot_widget.php 92% from 13 tests

The principal PHP file in "Bot Libre Chatbot" v. 1.0 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("bot-libre-chatbot.php" instead of "embed_bot_widget.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected242 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP13324242

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity38.00
▷ Minimum class complexity38.00
▷ Maximum class complexity38.00
Average method complexity10.25
▷ Minimum method complexity1.00
▷ Maximum method complexity38.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin