Skip to content

stats in code review summary are completely off #18

@mrtwebdesign

Description

@mrtwebdesign

The counter for the stats is completely different from the scanning tool that has exclusions. They are files scanned, they are just a count of all php files in the root folder even if they are listed in .gitignore for the local repo.

Image

(fyi, I don't know why I ran those tools below in 2022, but those are standard for the things this plugin is trying to catch)

No, the vendor folder was NOT created by /dist code.

The vendor folder was created on August 24, 2022 (based on the timestamps) when someone ran composer require for PHP_CodeSniffer tools. It contains:

  • squizlabs/php_codesniffer - PHPCS linting tool
  • wp-coding-standards - WordPress coding standards
  • phpcompatibility - PHP version compatibility checks

The irony: The check-performance.sh script actually defines exclusions at line 60:
EXCLUDE_DIRS="vendor node_modules .git tests"

But the counting functions at lines 209-222 don't use these exclusions - they just do a raw find without applying EXCLUDE_DIRS. That's a bug in the tool.

Summary:

  1. vendor/ is from a previous PHPCS setup, not from /dist
  2. The tool knows it should exclude vendor (line 60) but the counting code doesn't apply it**
  3. The actual theme code is only 44 PHP files with 11,923 lines - not 1,204 files and 234K lines

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions