mozilla / treeherder
Source Code Overview

Analysis scope, overview of main, test, generated, deployment, build, and other code.

Source Code Analysis Scope
Files includes and excluded from analyses
txt
har
in
ini
gitattributes
cfg
mjs
prettierignore
Overview of Analyzed Files
Basic stats on analyzed files
Intro
For analysis purposes we separate files in scope into several categories: main, test, generated, deployment and build, and other.

  • The main category contains all manually created source code files that are being used in the production.
  • Files in the main category are used as input for other analyses: logical decomposition, concerns, duplication, file size, unit size, and conditional complexity.
  • Test source code files are used only for testing of the product. These files are normally not deployed to production.
  • Build and deployment source code files are used to configure or support build and deployment process.
  • Generated source code files are automatically generated files that have not been manually changed after generation.
  • While a source code folder may contain a number of files, we are primarily interested in the source code files that are being written and maintained by developers.
  • Files containing binaries, documentation, or third-party libraries, for instance, are excluded from analysis. The exception are third-party libraries that have been changed by developers.

main58286 LOC (44%) 545 files
test24930 LOC (18%) 207 files
generated0 LOC (0%) 0 files
build and deployment381 LOC (<1%) 4 files
other48701 LOC (36%) 145 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
mjs
in
cfg
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 545 files match defined criteria (58,286 LOC, 100.0% vs. main code):
    • 181 *.jsx files (29,498 LOC)
    • 279 *.py files (19,427 LOC)
    • 55 *.js files (5,424 LOC)
    • 22 *.css files (3,556 LOC)
    • 2 *.yaml files (187 LOC)
    • 1 *.mjs files (71 LOC)
    • 1 *.toml files (46 LOC)
    • 2 *.in files (40 LOC)
    • 1 *.html files (22 LOC)
    • 1 *.cfg files (15 LOC)
  • " *.jsx" is biggest, containing 50.61% of LOC.
  • " *.cfg" is smallest, containing 0.03% of LOC.


*.jsx29498 LOC (50%) 181 files
*.py19427 LOC (33%) 279 files
*.js5424 LOC (9%) 55 files
*.css3556 LOC (6%) 22 files
*.yaml187 LOC (<1%) 2 files
*.mjs71 LOC (<1%) 1 file
*.toml46 LOC (<1%) 1 file
*.in40 LOC (<1%) 2 files
*.html22 LOC (<1%) 1 file
*.cfg15 LOC (<1%) 1 file
Test Code
Used only for testing of the product. Normally not deployed in a production environment.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/[Tt]ests/.*".
    • files with paths like ".*/test_.*".
    • files with paths like ".*_test[.].*".
    • files with paths like ".*/tests_.*".
    • files with paths like ".*/e2e/.*".
    • files with paths like ".*_tests[.].*".
    • files with paths like ".*/jest[.][a-zA-Z0-9\.]+".
    • files with paths like ".*/testing[.].*".
  • 207 files match defined criteria (24,930 LOC, 42.8% vs. main code):
    • 134 *.py files (14,858 LOC)
    • 57 *.jsx files (9,177 LOC)
    • 14 *.js files (860 LOC)
    • 1 *.yaml files (28 LOC)
    • 1 *.bat files (7 LOC)
  • " *.py" is biggest, containing 59.6% of LOC.
  • " *.bat" is smallest, containing 0.03% of LOC.


*.py14858 LOC (59%) 134 files
*.jsx9177 LOC (36%) 57 files
*.js860 LOC (3%) 14 files
*.yaml28 LOC (<1%) 1 file
*.bat7 LOC (<1%) 1 file
Build and Deployment Code
Source code used to configure or support build and deployment process.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]git[a-z]+".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]bat".
    • files with paths like ".*([.]|/)webpack([.]|/).*".
    • files with paths like ".*/[.]gitattributes".
    • files with paths like ".*[.]sh".
    • files with paths like ".*/package[.]json".
  • 4 files match defined criteria (381 LOC, 0.7% vs. main code):
    • 1 *.js files (293 LOC)
    • 3 *.sh files (88 LOC)
  • " *.js" is biggest, containing 76.9% of LOC.
  • " *.sh" is smallest, containing 23.1% of LOC.


*.js293 LOC (76%) 1 file
*.sh88 LOC (23%) 3 files
Other Code
txt
ini
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]txt".
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*/LICENSE[.][a-z0-9]+".
    • files with paths like ".*[.]ini".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*/[.]dockerignore".
    • files with paths like ".*[.]json".
    • files with paths like ".*/[.]prettierignore".
  • 145 files match defined criteria (48,701 LOC, 83.6% vs. main code):
    • 134 *.json files (45,818 LOC)
    • 5 *.txt files (2,683 LOC)
    • 4 *.md files (128 LOC)
    • 2 *.ini files (72 LOC)
  • " *.json" is biggest, containing 94.08% of LOC.
  • " *.ini" is smallest, containing 0.15% of LOC.


*.json45818 LOC (94%) 134 files
*.txt2683 LOC (5%) 5 files
*.md128 LOC (<1%) 4 files
*.ini72 LOC (<1%) 2 files
Analyzers
Info about analyzers used for source code examinations.


2025-05-11 19:41