radon-repository-scorer
The radon-repository-scorer is a Python package to compute a repository best engineering practices indicators.
The module provides the following 8 indicators of well-engineered software projects:
- Core contributors: the number of contributors whose total number of commits accounts for 80% or more of the total contributions.
- Continuous integration (CI): the repository has evidence of a CI service, determined by the presence of a configuration file required by that service (e.g., a.travis.ymlfor TravisCI).
- Comments ratio: ratio between comments and lines of code.
- Commit frequency: the average number of commits per month.
- Issue frequency: the average number of issue events transpired per month.
- License availability: the repository has evidence of a license (i.e., a LICENSE file).
- Lines of Code: the number of executable lines of code.
- Ratio of IaC scripts: ratio between Infrastructure-as-Code (IaC) files and total files.
All the previous indicators but the last are described in depth in:
@inproceedings{@article{munaiah2017curating,
title={Curating GitHub for engineered software projects},
author={Munaiah, Nuthan and Kroh, Steven and Cabrey, Craig and Nagappan, Meiyappan},
journal={Empirical Software Engineering},
volume={22},
number={6},
pages={3219--3253},
year={2017},
publisher={Springer}
}
Note: the tool is intended to be used as a Python library. Therefore, the current version does not provide a command line interface.
How to install
From the Python Package Index
pip install repository-scorer
From source code
pip install -r requirements
pip install .
How to use
from reposcorer.scorer import score_repository
report = score_repository(clone_to='path/to/a/dir/',
full_name_or_id='repo_owner/repo_name', # e.g., radon-h2020/radon-repository-scorer
host='github', # or gitlab
calculate_comments_ratio= True,
calculate_commit_frequency=True,
calculate_core_contributors=True,
calculate_has_ci=True,
calculate_has_license=True,
calculate_iac_ratio=True,
calculate_issue_frequency=True,
calculate_repository_size=True)
Output
{
'has_ci': <bool>,
'comments_ratio': <float in [0,1]>,
'commit_frequency': <float>,
'core_contributors': <int>,
'iac_ratio': <float in [0,1]>,
'issue_frequency': <float>,
'has_license': <bool>,
'repository_size': <int>
}
See CHANGELOG for logs detail about releases.
Metadata
Release files for repository-scorer 0.5.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| repository-scorer-0.5.1.tar.gz | 12.5 kB | Without provenance | Details for repository-scorer-0.5.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| repository_scorer-0.5.1-py3-none-any.whl | Python 3 | none | any | Details for repository_scorer-0.5.1-py3-none-any.whl |
Total release size: 26.7 kB
Release files / repository-scorer-0.5.1.tar.gz
| Download URL | repository-scorer-0.5.1.tar.gz |
|---|---|
| Size | 12.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b87f33d5f0caf3814aa460797514f7729d4cbaf9d6b159ba8cf1cb62be8dd16c
|
|
BLAKE2b-256 checksum How to use checksums |
1f5f0c33e7b93c1ec538dcd4224fe59eb431045f9da14c4b79c4d6d10d85e852
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
|
Release files / repository_scorer-0.5.1-py3-none-any.whl
| Download URL | repository_scorer-0.5.1-py3-none-any.whl |
|---|---|
| Size | 14.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1b60bb1c3839d338b791fc5bc718ae0f64cf1860b34236e53c731c1a28eaa06b
|
|
BLAKE2b-256 checksum How to use checksums |
cfe20ae2022872ef2372ba37caacca7ef186f81a3c9fa77af5cdf3f798fc857d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
|
Security for repository-scorer 0.5.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.