def METHOD_NAME(revision: Optional[str]) -> str:
    """Defines the revision -> model mapping"""
    if not revision or "v" not in revision:
        log.error(f"bad revision: {revision}")
        return "magneticModuleV1"
    try:
        revision_num = float(revision.split("v")[-1])
    except (ValueError, TypeError):
        log.exception("bad revision: {revision}")
        return "magneticModuleV1"
    if revision_num < MagDeck.FIRST_GEN2_REVISION:
        return "magneticModuleV1"
    else:
        return "magneticModuleV2"