def METHOD_NAME(event, hint):
    # type: (Event, Hint) -> Optional[Event]
    hub = Hub.current
    with capture_internal_exceptions():
        if hub.scope.transaction is not None:
            hub.scope.transaction.name = ctx["job_name"]
            event["transaction"] = ctx["job_name"]
        tags = event.setdefault("tags", {})
        tags["arq_task_id"] = ctx["job_id"]
        tags["arq_task_retry"] = ctx["job_try"] > 1
        extra = event.setdefault("extra", {})
        extra["arq-job"] = {
            "task": ctx["job_name"],
            "args": args
            if _should_send_default_pii()
            else SENSITIVE_DATA_SUBSTITUTE,
            "kwargs": kwargs
            if _should_send_default_pii()
            else SENSITIVE_DATA_SUBSTITUTE,
            "retry": ctx["job_try"],
        }
    return event