def METHOD_NAME(artifact_path, pep_number, path):
    image_path = os.path.join(artifact_path, path)
    if not os.path.exists(image_path):
        print(f"Image Path '{image_path}' does not exist, skipping")
        return
    try:
        page = Page.objects.get(path=pep_url(pep_number))
    except Page.DoesNotExist:
        print(f"Could not find backing PEP {pep_number}")
        return
    # Find existing images, we have to loop here as we can't use the ORM
    # to query against image__path
    existing_images = Image.objects.filter(page=page)
    FOUND = False
    for image in existing_images:
        if image.image.name.endswith(path):
            FOUND = True
            break
    if not FOUND:
        image = Image(page=page)
        with open(image_path, 'rb') as image_obj:
            image.image.save(path, File(image_obj))
        image.save()
    # Old images used to live alongside html, but now they're in different
    # places, so update the page accordingly.
    soup = BeautifulSoup(page.content.raw, 'lxml')
    for img_tag in soup.findAll('img'):
        if img_tag['src'] == path:
            img_tag['src'] = image.image.url
    page.content.raw = str(soup)
    page.save()
    return image