Benchmarks
Plugin footprint 82% 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: ▲0.01MB] [CPU: ▼2.68ms] Passed 4 tests
This is a short check of server-side resources used by GSY Export Posts to PDF
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 43.50 ▼5.14 |
Dashboard /wp-admin | 3.32 ▲0.02 | 51.96 ▲0.24 |
Posts /wp-admin/edit.php | 3.37 ▲0.02 | 53.38 ▲2.97 |
Add New Post /wp-admin/post-new.php | 5.90 ▲0.02 | 92.12 ▼0.77 |
Media Library /wp-admin/upload.php | 3.24 ▲0.02 | 38.01 ▼5.06 |
Export Posts to PDF /wp-admin/options-general.php?page=gsy-export-posts-to-pdf | 3.21 | 31.36 |
Server storage [IO: ▲27.25MB] [DB: ▲0.00MB] 67% from 3 tests
How much does this plugin use your filesystem and database?
These are issues you should consider
- The filesystem usage should be lower than 25MB (currently using 27.25MB)
Filesystem: 169 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
theysaidso_admin_options |
widget_theysaidso_widget |
db_upgraded |
widget_recent-posts |
widget_recent-comments |
Browser metrics Passed 4 tests
GSY Export Posts to PDF: an overview of browser usage
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,829 ▲40 | 13.23 ▼1.17 | 4.73 ▲2.74 | 45.19 ▲2.25 |
Dashboard /wp-admin | 2,204 ▼2 | 5.94 ▲1.10 | 101.92 ▼9.83 | 39.67 ▼3.49 |
Posts /wp-admin/edit.php | 2,093 ▲1 | 1.97 ▼0.08 | 41.12 ▲3.39 | 41.58 ▲7.80 |
Add New Post /wp-admin/post-new.php | 1,545 ▲11 | 18.23 ▼5.06 | 710.05 ▲19.66 | 57.22 ▼0.82 |
Media Library /wp-admin/upload.php | 1,383 ▼8 | 4.23 ▲0.01 | 97.60 ▼10.68 | 42.30 ▼4.93 |
Export Posts to PDF /wp-admin/options-general.php?page=gsy-export-posts-to-pdf | 810 | 2.03 | 27.01 | 27.34 |
Uninstaller [IO: ✅] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
- This plugin did not uninstall successfully, leaving 6 options in the database
- can_compress_scripts
- db_upgraded
- widget_recent-posts
- theysaidso_admin_options
- widget_recent-comments
- widget_theysaidso_widget
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected
SRP 0% 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
Please take a closer look at the following
- 2× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/utils/index.php
- > /wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/compress.php
- 48× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Warning
Use of undefined constant _JPGRAPH_PATH - assumed '_JPGRAPH_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/graph.php on line 32
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/config.php:5
- > PHP Fatal error
'break' not in the 'loop' or 'switch' context in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/classes/svg.php on line 2311
- > PHP Warning
Use of undefined constant _JPGRAPH_PATH - assumed '_JPGRAPH_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/graph.php on line 25
- > PHP Warning
include_once(_JPGRAPH_PATHjpgraph_regstat.php): failed to open stream: No such file or directory in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/graph.php on line 28
- > PHP Notice
Undefined index: dest in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/includes/out.php on line 8
- > PHP Warning
include_once(): Failed opening '_JPGRAPH_PATHjpgraph_radar.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/graph.php on line 32
- > PHP Warning
Use of undefined constant _MPDF_PATH - assumed '_MPDF_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/classes/ttfontsuni_analysis.php on line 3
- > PHP Warning
include_once(_JPGRAPH_PATHjpgraph_radar.php): failed to open stream: No such file or directory in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/graph.php on line 32
- > PHP Warning
opendir(_MPDF_PATHgraph_cache): failed to open dir: No such file or directory in wp-content/plugins/gsy-export-posts-to-pdf/libraries/mpdf/graph.php on line 13
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
4 plugin tags: pdf, gsy, export, posts
gsy-export-posts-to-pdf/gsy-export-posts-to-pdf.php Passed 13 tests
"GSY Export Posts to PDF" version 1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
20 characters long description:
Export posts to pdf.
Code Analysis 95% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin65,130 lines of code in 90 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 85 | 5,171 | 5,324 | 64,977 |
CSS | 4 | 11 | 19 | 94 |
PO File | 1 | 21 | 22 | 59 |
PHP code 0% from 2 tests
Analyzing cyclomatic complexity and code structure
These items need your attention
- Cyclomatic complexity of classes should be reduced to less than 1000 (currently 10,031)
- Method cyclomatic complexity has to be reduced to less than 100 (currently 1,527)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.52 |
Average class complexity | 509.54 |
▷ Minimum class complexity | 4.00 |
▷ Maximum class complexity | 10,031.00 |
Average method complexity | 21.92 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 1,527.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 26 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 26 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 632 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 611 | 96.68% |
▷ Protected methods | 21 | 3.32% |
▷ Private methods | 0 | 0.00% |
Functions | 23 | |
▷ Named functions | 23 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 47 | |
▷ Global constants | 47 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
There were not PNG files found in your plugin