joeyberkovitz opened a new issue #21625: URL: https://github.com/apache/airflow/issues/21625
### Apache Airflow version 2.2.3 (latest released) ### What happened The included LocalFileSystem secrets backend has a minor bug that prevents importing of connections from ".env" files containing multiple "=" characters. On https://github.com/apache/airflow/blob/main/airflow/secrets/local_filesystem.py#L77 - the Python string split function is used and the `maxsplit` parameter is set to 2 when instead it should be set to 1. Per the Python docs: https://docs.python.org/3.11/library/stdtypes.html?#str.split - the result of split will be a list with at most `maxsplit + 1` elements. ### What you expected to happen Connections with "=" in ".env" files are accepted ### How to reproduce In airflow.cfg under `[secrets]` - backend = airflow.secrets.local_filesystem.LocalFilesystemBackend - backend_kwargs = {"connections_file_path": "/test_file.env"} In /test_file.env - specify a connection containing multiple "=" characters Run `airflow connections get CONN_ID` and observe error ### Operating System All ### Versions of Apache Airflow Providers _No response_ ### Deployment Other ### Deployment details _No response_ ### Anything else _No response_ ### Are you willing to submit PR? - [ ] 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]
