Datamap sheet field issues #14
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
If a sheet-block (however many rows pertaining to a particular sheet) of rows in the datamap has its sheet field missing/blank, then that row will now migrate during the
exportprocess, However, if the first row of the block is intact and the other sheet fields are missing for that particular block, then the data will actually be migrated.This will cause a problem if the gap in the sheet entries spans the boundaries between blocks because the program won't know where the change in sheet happens.
Example:
The code handling this is currently at
engine/repository/templates.py(39),_populate_workbook(). The test istest_populate_templates_from_master.py.test_export_continues_with_missing_sheet_in_datamap`.The best solution here is to use the initial datamap check to ensure that every datamap row has the requisite fields, and warn the user before it procedes.
New test required in
test_datamap_parser.py- stub created. Need to focus onengine.utils.extraction.datamap_reader()which should reject any badly formatted datamap file. All exceptions raised here should be passed tomain()and handled with appropriate log messages.Fixed by raising exception when
sheetfield is missing, and datamaps quits, asking the user to correct the datamap.