sample_metadata/parser/generic_parser.py
def create_secondary_file_objects_by_potential_pattern(
        self, filename, potential_secondary_patterns: List[str]
    ) -> List[Dict[str, Any]]:
        """
        Take a base filename and potential secondary patterns:
        - Try each secondary pattern, see if it works
        - If it works, create a CWL file object
        - return a list of those secondary file objects that exist
        """
        secondaries = []
        for sec in potential_secondary_patterns:
            sec_file = _apply_secondary_file_format_to_filename(filename, sec)
            if self.skip_checking_gcs_objects or self.file_exists(sec_file):
                secondaries.append(self.create_file_object(sec_file))

        return secondaries

        Take a base filename and potential secondary patterns:
        - Try each secondary pattern, see if it works
        - If it works, create a CWL file object
        - return a list of those secondary file objects that exist
        
Take a base filename and potential secondary patterns:
Try each secondary pattern, see if it works
If it works, create a CWL file object
return a list of those secondary file objects that exist
Take a base filename and potential secondary patterns : Try each secondary pattern see if it works If it works create a CWL file object return a list of those secondary file objects that exist
def create_secondary_file_objects_by_potential_pattern(
        self, filename, potential_secondary_patterns: List[str]
    ) -> List[Dict[str, Any]]:
        secondaries = []
        for sec in potential_secondary_patterns:
            sec_file = _apply_secondary_file_format_to_filename(filename, sec)
            if self.skip_checking_gcs_objects or self.file_exists(sec_file):
                secondaries.append(self.create_file_object(sec_file))
        return secondaries
def create_secondary_file_objects_by_potential_pattern ( self , filename , potential_secondary_patterns : List [ str ] ) -> List [ Dict [ str , Any ] ] : secondaries = [ ] for sec in potential_secondary_patterns : sec_file = _apply_secondary_file_format_to_filename ( filename , sec ) if self . skip_checking_gcs_objects or self . file_exists ( sec_file ) : secondaries . append ( self . create_file_object ( sec_file ) ) return secondaries
Take a base filename and potential secondary patterns:
 Try each secondary pattern, see if it works
 If it works, create a CWL file object
 return a list of those secondary file objects that exist
Take a base filename and potential secondary patterns : Try each secondary pattern see if it works If it works create a CWL file object return a list of those secondary file objects that exist
"""
        Take a base filename and potential secondary patterns:
        - Try each secondary pattern, see if it works
        - If it works, create a CWL file object
        - return a list of those secondary file objects that exist
        """
self
filename
potential_secondary_patterns
List[str]