84% clockwork-wp

Code Review | Clockwork WP

WordPress plugin Clockwork WP scored84%from 54 tests.

About plugin

  • Plugin page: clockwork-wp
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8.0-4.0
  • WordPress version: 6.3.1
  • First release: Jul 25, 2014
  • Latest release: Jul 25, 2014
  • Number of updates: 12
  • Update frequency: N/A
  • Top authors: bretterer (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /885 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.20MB] [CPU: ▼6.77ms] Passed 4 tests

Analyzing server-side resources used by Clockwork WP
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.98 ▲0.2548.95 ▲1.41
Dashboard /wp-admin3.81 ▲0.1855.03 ▼13.08
Posts /wp-admin/edit.php3.85 ▲0.1753.85 ▼1.14
Add New Post /wp-admin/post-new.php6.39 ▲0.2491.67 ▼14.26
Media Library /wp-admin/upload.php3.71 ▲0.2239.77 ▲1.59

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 78 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Clockwork WP
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.38 ▲0.012.29 ▲0.4443.20 ▲0.68
Dashboard /wp-admin2,198 ▲215.65 ▼0.0095.59 ▲3.6343.00 ▼0.63
Posts /wp-admin/edit.php2,097 ▼32.00 ▲0.0036.42 ▼0.3033.79 ▼4.64
Add New Post /wp-admin/post-new.php1,545 ▲1923.24 ▲5.85634.94 ▼35.0850.56 ▼6.62
Media Library /wp-admin/upload.php1,391 ▼94.19 ▼0.0799.12 ▼12.5745.97 ▲0.44

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
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options

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
Good news, no errors were detected

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
  • 25× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Clockwork\\Storage\\Storage' not found in wp-content/plugins/clockwork-wp/vendor/itsgoingd/clockwork/Clockwork/Storage/FileStorage.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'Clockwork\\DataSource\\DataSource' not found in wp-content/plugins/clockwork-wp/vendor/itsgoingd/clockwork/Clockwork/DataSource/LaravelDataSource.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'Slim\\Middleware' not found in wp-content/plugins/clockwork-wp/vendor/itsgoingd/clockwork/Clockwork/Support/Slim/ClockworkMiddleware.php:11
    • > PHP Fatal error
      Uncaught Error: Interface 'Clockwork\\DataSource\\DataSourceInterface' not found in wp-content/plugins/clockwork-wp/vendor/itsgoingd/clockwork/Clockwork/DataSource/DataSource.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/clockwork-wp/vendor/psr/log/Psr/Log/Test/LoggerInterfaceTest.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'Illuminate\\Support\\ServiceProvider' not found in wp-content/plugins/clockwork-wp/vendor/itsgoingd/clockwork/Clockwork/Support/Laravel/ClockworkServiceProvider.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'Clockwork\\DataSource\\DataSource' not found in wp-content/plugins/clockwork-wp/vendor/itsgoingd/clockwork/Clockwork/DataSource/PhpDataSource.php:10
    • > PHP Fatal error
      Uncaught Error: Interface 'Swift_Events_SendListener' not found in wp-content/plugins/clockwork-wp/vendor/itsgoingd/clockwork/Clockwork/Support/Swift/SwiftPluginClockworkTimeline.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'Clockwork\\DataSource\\DataSource' not found in wp-content/plugins/clockwork-wp/vendor/itsgoingd/clockwork/Clockwork/DataSource/MonologDataSource.php:13
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Log\\LoggerInterface' not found in wp-content/plugins/clockwork-wp/vendor/psr/log/Psr/Log/AbstractLogger.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
3 plugin tags: debug, development, clockwork

clockwork-wp/clockwork-wp.php Passed 13 tests

The principal PHP file in "Clockwork WP" v. 1.0.0 is loaded by WordPress automatically on each request
31 characters long description:
WordPress plugin for Clockwork.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin2,335 lines of code in 73 files:
LanguageFilesBlank linesComment linesLines of code
PHP445471,0331,964
Markdown4720205
JSON2500166

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity5.18
▷ Minimum class complexity1.00
▷ Maximum class complexity37.00
Average method complexity1.81
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces12
Interfaces4
Traits2
Classes33
▷ Abstract classes39.09%
▷ Concrete classes3090.91%
▷ Final classes00.00%
Methods194
▷ Static methods115.67%
▷ Public methods15981.96%
▷ Protected methods3216.49%
▷ Private methods31.55%
Functions28
▷ Named functions725.00%
▷ Anonymous functions2175.00%
Constants10
▷ Global constants110.00%
▷ Class constants990.00%
▷ Public constants9100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin