Is this the preferred way to detect if the unicode or non-unicode version of cx_oracle was installed?
문제
I have a custom module that's basically a thin wrapper around a database connection with cx_Oracle. I'd like to re-use this module on computers with both the unicode version of cx_Oracle installed, and with the non-unicode version.
To do this, I need to "detect" the version installed. I could "try" making a connection using a string connection descriptor; and if I get a TypeError back, then assume it's the unicode version installed. This just seems a bit kludgy.
Is there a better/preferred way of doing this?
Thanks.
올바른 솔루션이 없습니다
제휴하지 않습니다 StackOverflow