Owen-CH-Leung opened a new issue, #53527:
URL: https://github.com/apache/airflow/issues/53527

   ### Apache Airflow Provider(s)
   
   opensearch
   
   ### Versions of Apache Airflow Providers
   
   Airflow 3
   
   ### Apache Airflow version
   
   3
   
   ### Operating System
   
   Debian GNU/Linux 12 (bookworm)
   
   ### Deployment
   
   Docker-Compose
   
   ### Deployment details
   
   I use breeze to start an airflow
   
   `breeze start-airflow --executor CeleryExecutor --backend postgres 
--load-example-dags --db-reset`
   
   ### What happened
   
   At main branch, export the following environment variable:
   
   ```
   AIRFLOW__LOGGING__REMOTE_LOGGING=True
   AIRFLOW__LOGGING__REMOTE_LOG_CONN_ID="opensearch_default"
   AIRFLOW__OPENSEARCH__HOST="http://my-opensearch-01:9200";
   AIRFLOW__OPENSEARCH__JSON_FORMAT=True
   AIRFLOW__OPENSEARCH__OFFSET_FIELD="offset"
   AIRFLOW__OPENSEARCH__WRITE_STDOUT=True
   AIRFLOW__OPENSEARCH__USERNAME="admin"
   AIRFLOW__OPENSEARCH__PASSWORD="admin"
   ```
   
   Then start the webserver process `airflow api-server`. Then in the browser 
visit `localhost:28080`, the process will return error:
   
   ```
   INFO:     192.168.65.1:20194 - "GET /ui/config HTTP/1.1" 500 Internal Server 
Error
   ERROR:    Exception in ASGI application
   Traceback (most recent call last):
   ......
   ......
     File 
"/usr/local/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 
967, in run
       result = context.run(func, *args)
     File 
"/opt/airflow/airflow-core/src/airflow/api_fastapi/core_api/routes/ui/config.py",
 line 64, in get_configs
       return ConfigResponse.model_validate(config)
     File "/usr/local/lib/python3.10/site-packages/pydantic/main.py", line 705, 
in model_validate
       return cls.__pydantic_validator__.validate_python(
   pydantic_core._pydantic_core.ValidationError: 1 validation error for 
ConfigResponse
   show_external_log_redirect
     Input should be a valid boolean [type=bool_type, input_value=None, 
input_type=NoneType]
       For further information visit 
https://errors.pydantic.dev/2.11/v/bool_type
   ```
   
   
   ### What you think should happen instead
   
   When using `OpensearchTaskHandler` as remote log handler, the `airflow 
api-server` should successfully run without returning `500 Internal Server 
Error`
   
   ### How to reproduce
   
   As described 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)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to