### Apache Airflow version

2.2.0 (latest released)

### Operating System

Debian GNU/Linux 11 (bullseye)

### Versions of Apache Airflow Providers

N/A

### Deployment

Other Docker-based deployment

### Deployment details

CeleryExecutor / ECS / Postgres

### What happened

![image](https://user-images.githubusercontent.com/160865/139075540-25fca98f-a858-49ce-8f3f-1b9a145a6853.png)

Clicking on logs / instance details on the following dialog causes an exception:

```
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/flask/app.py", line 2447, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python3.9/site-packages/flask/app.py", line 1952, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python3.9/site-packages/flask/app.py", line 1821, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python3.9/site-packages/flask/_compat.py", line 39, in reraise
    raise value
  File "/usr/local/lib/python3.9/site-packages/flask/app.py", line 1950, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python3.9/site-packages/flask/app.py", line 1936, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/local/lib/python3.9/site-packages/airflow/www/auth.py", line 51, in decorated
    return func(*args, **kwargs)
  File "/usr/local/lib/python3.9/site-packages/airflow/www/decorators.py", line 63, in wrapper
    log.execution_date = pendulum.parse(execution_date_value, strict=False)
  File "/usr/local/lib/python3.9/site-packages/pendulum/parser.py", line 29, in parse
    return _parse(text, **options)
  File "/usr/local/lib/python3.9/site-packages/pendulum/parser.py", line 45, in _parse
    parsed = base_parse(text, **options)
  File "/usr/local/lib/python3.9/site-packages/pendulum/parsing/__init__.py", line 74, in parse
    return _normalize(_parse(text, **_options), **_options)
  File "/usr/local/lib/python3.9/site-packages/pendulum/parsing/__init__.py", line 120, in _parse
    return _parse_common(text, **options)
  File "/usr/local/lib/python3.9/site-packages/pendulum/parsing/__init__.py", line 177, in _parse_common
    return date(year, month, day)
ValueError: year 0 is out of range
```
This is because the execution_date in the query param of the url is empty i.e:

`http://localhost:50008/log?dag_id=test_logging&task_id=check_exception_to_sentry&execution_date=`

### What you expected to happen

The logs to load / task instance detail page to load

### How to reproduce

See above

### Anything else

_No response_

### Are you willing to submit PR?

- [X] Yes I am willing to submit a PR!

### Code of Conduct

- [X] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)

airflow/www/views.py
"""Filter using DagIDs"""
    def apply(self, query, func):  
        filter_dag_ids = current_app.appbuilder.sm.get_editable_dag_ids(g.user)
        return query.filter(self.model.dag_id.in_(filter_dag_ids))
class AirflowModelView(ModelView):
    """Airflow Mode View."""
    list_widget = AirflowModelListWidget
    page_size = PAGE_SIZE
    CustomSQLAInterface = wwwutils.CustomSQLAInterface
class AirflowPrivilegeVerifierModelView(AirflowModelView):
    """
    This ModelView prevents ability to pass primary keys of objects relating to DAGs you shouldn't be able to
    edit. This only holds for the add, update and delete operations.
    You will still need to use the `action_has_dag_edit_access()` for actions.
    """
    @staticmethod
    def validate_dag_edit_access(item: Union[DagRun, TaskInstance]):
        """Validates whether the user has 'can_edit' access for this specific DAG."""
        if not current_app.appbuilder.sm.can_edit_dag(item.dag_id):
            raise AirflowException(f"Access denied for dag_id {item.dag_id}")
    def pre_add(self, item: Union[DagRun, TaskInstance]):
        self.validate_dag_edit_access(item)
    def pre_update(self, item: Union[DagRun, TaskInstance]):
        self.validate_dag_edit_access(item)
    def pre_delete(self, item: Union[DagRun, TaskInstance]):
        self.validate_dag_edit_access(item)
    def post_add_redirect(self):  
        return redirect(self.get_default_url())
    def post_edit_redirect(self):