pacificclimate / climate-explorer-data-prep

0 stars 0 forks source link

Refactor input checking procedures in decompose_flow_vectors script #126

Closed sum1lim closed 4 years ago

sum1lim commented 4 years ago

Currently, decompose_flow_vectors script's main(args) contains input(source and variable) checking procedures. This is somewhat not ideal when the program is called in another program such as thunderbird. Passing args as a parameter makes it hard to call the main() function when the program that imports decompose_flow_vectors does not run using terminal input. Therefore, it is necessary to copy the input checking procedure from the script to the newly implemented program, which is redundant to have duplicate codes. To avoid this, refactor the procedure into source_check() and variable_check() functions.