Reference
parse_main_params
Parse and validate a MAIN_PARAMS.xlsx workbook.
This function
- Verifies that the Excel file exists.
- Reads required sheets using pandas.
- Validates required columns.
- Transforms each sheet into business mappings.
- Returns an immutable MainParams instance.
The returned object provides explicit getter methods to safely access referential values.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
file_path
|
Path
|
Path to the MAIN_PARAMS.xlsx file. |
required |
Returns:
| Type | Description |
|---|---|
MainParams
|
A validated MainParams object containing referential mappings. |
Raises:
| Type | Description |
|---|---|
FileNotFoundError
|
If the file does not exist. |
ValueError
|
If required sheets or columns are missing. |