scripts/fixer.py
def redownload(full_path):
    """Redownload the specified file.

    Parameters
    ----------
    full_path : str
        The relative file path of the HTML document.

    """

    file_id = full_path.split("/")[-1].replace(".html", "")
    base_url = f"https://www.empleo.gob.mx/{file_id}-oferta-de-empleo-de-empleado-test-"

    with requests.get(base_url, headers=HEADERS, verify=False) as response:

        with open(full_path, "w", encoding="utf-8") as temp_file:
            temp_file.write(response.text)
            print("Redownloaded:", full_path)
            time.sleep(1)
Redownload the specified file.

    Parameters
    ----------
    full_path : str
        The relative file path of the HTML document.

    
Redownload the specified file.
Parameters

full_path : str
The relative file path of the HTML document.
Redownload the specified file . Parameters full_path : str The relative file path of the HTML document .
def redownload(full_path):
    file_id = full_path.split("/")[-1].replace(".html", "")
    base_url = f"https://www.empleo.gob.mx/{file_id}-oferta-de-empleo-de-empleado-test-"
    with requests.get(base_url, headers=HEADERS, verify=False) as response:
        with open(full_path, "w", encoding="utf-8") as temp_file:
            temp_file.write(response.text)
            print("Redownloaded:", full_path)
            time.sleep(1)
def redownload ( full_path ) : file_id = full_path . split ( "/" ) [ - 1 ] . replace ( ".html" , "" ) base_url = f"https://www.empleo.gob.mx/{file_id}-oferta-de-empleo-de-empleado-test-" with requests . get ( base_url , headers = HEADERS , verify = False ) as response : with open ( full_path , "w" , encoding = "utf-8" ) as temp_file : temp_file . write ( response . text ) print ( "Redownloaded:" , full_path ) time . sleep ( 1 )
Redownload the specified file.
Redownload the specified file .
"""Redownload the specified file.

    Parameters
    ----------
    full_path : str
        The relative file path of the HTML document.

    """
full_path