in KubernetesPodOperator the name parameter is mandatory.
However if you forget to add it you will get a broken dag message with:
![Screen Shot 2021-04-12 at 12 16 58](https://user-images.githubusercontent.com/62940116/114373136-f699d180-9b8a-11eb-8500-d8e7118650ae.png)

This is because
https://github.com/apache/airflow/blob/1dfbb8d2031cb8a3e95e4bf91aa478857c5c3a85/airflow/providers/cncf/kubernetes/operators/kubernetes_pod.py#L277

it calls validate_data which produce this error:
https://github.com/apache/airflow/blob/1dfbb8d2031cb8a3e95e4bf91aa478857c5c3a85/airflow/utils/helpers.py#L40

The error is not useful. It doesn't explain what the issue is of where the problem is. it also says problem with `key` which isn't a parameter of anything.
I couldn't even know that the issue is from the KubernetesPodOperator.

Suggestions:
make better error message for `KubernetesPodOperator` when name parameter is missing OR invalid.

I would also suggest to make validate_key produce a better error message specifying what object produce the error
tests/providers/cncf/kubernetes/operators/test_kubernetes_pod.py
#
#
import unittest
from unittest import mock
import pendulum
import pytest
from kubernetes.client import ApiClient, models as k8s
from airflow.exceptions import AirflowException
from airflow.models import DAG, TaskInstance
from airflow.providers.cncf.kubernetes.operators.kubernetes_pod import KubernetesPodOperator
from airflow.utils import timezone
class TestKubernetesPodOperator(unittest.TestCase):
    @staticmethod
    def create_context(task):
        dag = DAG(dag_id="dag")
        tzinfo = pendulum.timezone("Europe/Amsterdam")
        execution_date = timezone.datetime(2016, 1, 1, 1, 0, 0, tzinfo=tzinfo)
        task_instance = TaskInstance(task=task, execution_date=execution_date)
        return {
            "dag": dag,
            "ts": execution_date.isoformat(),
            "task": task,
            "ti": task_instance,
        }
    @mock.patch("airflow.providers.cncf.kubernetes.utils.pod_launcher.PodLauncher.start_pod")
    @mock.patch("airflow.providers.cncf.kubernetes.utils.pod_launcher.PodLauncher.monitor_pod")
    @mock.patch("airflow.kubernetes.kube_client.get_kube_client")
    def test_config_path(self, client_mock, monitor_mock, start_mock):