Architecture of datacontract/datacontract-cli
datacontract/datacontract-cli is 617 source files holding 5,631 symbols across 6 modules, written mainly in Python, JavaScript, Shell. The largest module is tests, with 207 files, and 5 files are entry points into the dependency graph.
How datacontract-cli fits together
Commands enter through datacontract/cli.py, which defines the command-line entry point and dispatches each command to its module. A data contract, such as an ODCS YAML file, is read together with the server details it names. The ibis engine under datacontract/engines/ibis, including datacontract/engines/ibis/connections/connect.py and datacontract/engines/ibis/ibis_check_execute.py, connects to the data source and executes the schema and quality checks. datacontract/api.py exposes the same testing as a web server that accepts POST requests when the api extra is installed. Results and exported artifacts come out in the chosen format, and the same functionality can be called from Python through the DataContract class.
Largest modules
- tests: 207 files and 27,923 lines of code
- datacontract: 165 files and 35,197 lines of code
- root: 11 files and 853 lines of code
- docs: 5 files and 516 lines of code
- examples: 2 files and 22 lines of code
- .github: 1 file and 38 lines of code
Languages
By file count: Python 378 files, JavaScript 5 files, Shell 3 files, TypeScript 3 files, Dockerfile 1 file.
Documentation
Repowise documents datacontract-cli in 609 pages generated from the source, 17 of them written explanations of the repository and its modules. Module guides include:
- datacontract/breaking: Breaking Change Detection
- datacontract: CLI Command Entrypoints
- datacontract/config: CLI Context and Settings
More on datacontract-cli: summary and FAQ, codebase overview, code health.
Related guide: Best dependency graph tools for monorepos