Skip to content

project

etl_craft.config.project

Files a task names in the project directory: SQL files and ingestion scripts.

A task names its file by a path relative to its folder, such as sales/orders.sql under sql_files/. The name must stay inside that folder and the file must exist; anything else is a MetadataError that names the setting, the value and the folder, and suggests close matches.

sql_file

sql_file(config: ConnectorConfig, name: str, *, setting: str = 'SOURCE_SQL_FILE') -> Path

Return the .sql file name under the project's sql_files/.

ingestion_script

ingestion_script(config: ConnectorConfig, name: str, *, setting: str = 'SCRIPT_NAME') -> Path

Return the .py script name under the project's ingestion_scripts/.

project_file

project_file(directory: Path, name: str, *, setting: str, suffix: str) -> Path

Return file name inside directory; MetadataError when it is not usable.