src/extractor-lib/edfi_lms_extractor_lib/csv_generation/write.py
def _fill_in_missing_section_ids(
    dfs_to_write: Dict[str, DataFrame], all_section_ids: List[str]
) -> Dict[str, DataFrame]:
    """
    Fill in any missing DataFrames for a Section with an empty DataFrame

    Parameters
    ----------
    dfs_to_write: Dict[str, DataFrame]
        is a Dict of section id/DataFrame pairs
    all_section_ids: List[str]
        is a list of all known section ids


    Returns
    -------
    Dict[str, DataFrame]
        a new Dict of section id/DataFrame pairs, with missing DataFrames
        for a Section filled in
    """
    full_dfs_to_write = dfs_to_write.copy()
    for section_id in all_section_ids:
        if section_id not in full_dfs_to_write:
            full_dfs_to_write[section_id] = DataFrame()
    return full_dfs_to_write

    Fill in any missing DataFrames for a Section with an empty DataFrame

    Parameters
    ----------
    dfs_to_write: Dict[str, DataFrame]
        is a Dict of section id/DataFrame pairs
    all_section_ids: List[str]
        is a list of all known section ids


    Returns
    -------
    Dict[str, DataFrame]
        a new Dict of section id/DataFrame pairs, with missing DataFrames
        for a Section filled in
    
Fill in any missing DataFrames for a Section with an empty DataFrame
Parameters

Dict[str, DataFrame]
is a Dict of section id/DataFrame pairs
all_section_ids: List[str]
is a list of all known section ids

Returns

Dict[str, DataFrame]
a new Dict of section id/DataFrame pairs, with missing DataFrames
for a Section filled in
Fill in any missing DataFrames for a Section with an empty DataFrame Parameters Dict [ str DataFrame ] is a Dict of section id / DataFrame pairs all_section_ids : List [ str ] is a list of all known section ids Returns Dict [ str DataFrame ] a new Dict of section id / DataFrame pairs with missing DataFrames for a Section filled in
def _fill_in_missing_section_ids(
    dfs_to_write: Dict[str, DataFrame], all_section_ids: List[str]
) -> Dict[str, DataFrame]:
    full_dfs_to_write = dfs_to_write.copy()
    for section_id in all_section_ids:
        if section_id not in full_dfs_to_write:
            full_dfs_to_write[section_id] = DataFrame()
    return full_dfs_to_write
def _fill_in_missing_section_ids ( dfs_to_write : Dict [ str , DataFrame ] , all_section_ids : List [ str ] ) -> Dict [ str , DataFrame ] : full_dfs_to_write = dfs_to_write . copy ( ) for section_id in all_section_ids : if section_id not in full_dfs_to_write : full_dfs_to_write [ section_id ] = DataFrame ( ) return full_dfs_to_write
Fill in any missing DataFrames for a Section with an empty DataFrame
Parameters
Fill in any missing DataFrames for a Section with an empty DataFrame Parameters
"""
    Fill in any missing DataFrames for a Section with an empty DataFrame

    Parameters
    ----------
    dfs_to_write: Dict[str, DataFrame]
        is a Dict of section id/DataFrame pairs
    all_section_ids: List[str]
        is a list of all known section ids


    Returns
    -------
    Dict[str, DataFrame]
        a new Dict of section id/DataFrame pairs, with missing DataFrames
        for a Section filled in
    """
dfs_to_write
Dict[str, DataFrame]
all_section_ids
List[str]