Basel Library
Basel Library is a powerful tool designed for calculating, reporting, and analyzing the architecture of a project.
Key Concepts
- Abstraction: Level of definition vs implementation inside a component.
- Stability: Level of incoming and outgoing dependencies that a component has.
Installation
pip install basel
Reports
Abstract/Instability and Component Relationship reports are the main data you can obtain from an architecture. To generate each one, you can use the report and rel options.
Abstraction/Stability (AE) Report
basel report --path ./path/to/project
Output:
Component I A E
---------------------------------------- ---- ---- ----
path/to/project/module1 0.75 0.2 0.05
path/to/project/module2 1 0.8 0.8
path/to/project/module3 0.5 1 0.5
---------------------------------------- ---- ---- ----
Mean 0.75 0.67 0.45
Component Relationship (CRel) Report
This report uses a binary matrix, where 1 represents a relation, and 0 does not. All components are assigned to an index. Check the legend below the report to identify each component.
basel rel --path ./path/to/project
Output:
Components 1 2 3
------------ --- --- ---
1 0 1 0
2 0 0 1
3 0 0 0
Labels:
1: path/to/project/module1
2: path/to/project/module2
3: path/to/project/module3
Formatting
To define a format use the --format or the abbreviation -fmt.
| Format | Reports | Description |
|---|---|---|
| basic | AE, CRel | Basic and default format |
| html | AE, CRel | HTML format |
| mean_i | AE | Only Instability Mean |
| mean_a | AE | Only Abstraction Mean |
| mean_e | AE | Only Error Mean |
| mean | AE | Only Error Mean |
| uml | CRel | UML code |
Excluding
You can exclude components in your project, which can be helpful to define boundaries. To exclude, you can use the -e or --exclude argument.
Filtering
Is posible that the report results are very long, to get your desired components you can use the -f or --filter arguments.
Contributing
We welcome contributions! If you'd like to contribute to Basel, please follow these guidelines:
- Fork the repository.
- Create a new branch for your feature or bug fix.
- Make your changes and commit them with clear messages.
- Submit a pull request.
Thank you for your contribution!
Contact
If you have any questions or suggestions, feel free to insert new issue.
License
This project is licensed under the MIT License.
Metadata
Release files for basel 1.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| basel-1.1.2.tar.gz | 12.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| basel-1.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 30.3 kB
Release files / basel-1.1.2.tar.gz
| Download URL | basel-1.1.2.tar.gz |
|---|---|
| Size | 12.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
80548a85572136c59a73348429166b0737d8291b6da922b701de3f5bf0445883
|
|
BLAKE2b-256 checksum How to use checksums |
6ce8990f045eff036099d1ab2e122152a15421bc63d00a3334c46aa8ee5a97ed
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.10.12
|
Release files / basel-1.1.2-py3-none-any.whl
| Download URL | basel-1.1.2-py3-none-any.whl |
|---|---|
| Size | 17.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f020b157c0b86c0fd079716f4b36424e75a8b3e84335138892e7816a0a39b956
|
|
BLAKE2b-256 checksum How to use checksums |
89fec52594523e2b49f12a15374c20e29d5f25a3b0b24fe73971b88e8078d13d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.10.12
|