From 8d17fb5bc4b0dae0758e01a44d77d87acf2e686a Mon Sep 17 00:00:00 2001 From: Trygve Laugstøl Date: Thu, 14 Mar 2019 06:27:16 +0100 Subject: o Adding module for searching on element14. o Starting on functionality create orders. Very WIP. o Adding a concept of an "ee project". Can load a gitconfig-like config file. o Adding a tool to import a yaml file into a part xml file. --- src/ee/xml/bom_file_utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/ee/xml') diff --git a/src/ee/xml/bom_file_utils.py b/src/ee/xml/bom_file_utils.py index d1f8be9..063a7bd 100644 --- a/src/ee/xml/bom_file_utils.py +++ b/src/ee/xml/bom_file_utils.py @@ -28,13 +28,13 @@ def part_numbers(part: bomFile.Part) -> List[bomFile.PartNumber]: return pns.part_numberProp -def find_pn(part: bomFile.Part) -> str: +def find_pn(part: bomFile.Part) -> Optional[str]: for pn in part_numbers(part): if pn.distributor is None: return pn.value -def find_dpn(part: bomFile.Part, distributor: str) -> str: +def find_dpn(part: bomFile.Part, distributor: str) -> Optional[str]: for pn in part_numbers(part): if pn.distributor == distributor: return pn.value -- cgit v1.2.3