Skip to content

Generalize the export_lib.py > add() function #40

@demisjohn

Description

@demisjohn

Currently the add() function in export_lib.py, which formats values appropriately for the text export, has a hokey kludge of if/elif statements that are each specific to a particular text line.

eg.
"WAFER_ALIGN_REPEATS" uses elif np.size(val) == 10:... or
"OptPrealignment Marks " uses elif np.size(val)==2 ... AND if doubelstr==True

Instead should generalize for general code readability (eg. use on another system) using arguments to determine format, instead of size( ) of the list passed.

Arguments should only be things like "quoted", "string", "integer", "float" etc.
Thus another developer could guess how it's going to get formatted from the arguments passed. Currently, instead a different format is applied depending on the np.size( ) of the vlaue list passed, which would require a dev to scour the add( ) function to figure out what it's actually going to do!

Here's a link to the add() function:
https://github.com/demisjohn/ASML_JobCreator/blob/master/ASML_JobCreator/exportlib.py#L36

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions