cccs-jc opened a new issue #13531:
URL: https://github.com/apache/superset/issues/13531
Unable to pass boolean values to database connections. When configuring
mysql+mysqlconnector I'm able to do the following in the python interpreter
```
import sqlalchemy as db
engine = db.create_engine('mysql+mysqlconnector://<user>:<pass>@<host>',
connect_args={'auth_plugin':'mysql_clear_password', 'ssl_verify_cert': "False",
'ssl_ca': '/etc/ssl/certs/Entrust_Root_Certification_Authority.pem'})
con = engine.connect()
```
However when I try to do the same thing via the database connect of superset
it refuses the boolean value
```
{
"metadata_params": {},
"engine_params": {
"connect_args": {
"auth_plugin":"mysql_clear_password",
"ssl_verify_cert": False,
"ssl_ca":
"/etc/ssl/certs/Entrust_Root_Certification_Authority.pem"
}
}
}
```
If I change the value to be a string either "False" or "false" then the
connector rejects the configuration saying ssl_verify_cert should be a boolean.
### Expected results
Able to pass boolean configurations to underlying connection library. I
looks like there needs to be interpretation of the values to try and convert
them to boolean flags. This is actually done explicitly for the
allows_virtual_table_explore value.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]