Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Driver not loaded error. Are the plugins debug or release plugins? #34

Open
ben-hearn-sb opened this issue Aug 31, 2023 · 2 comments
Open

Comments

@ben-hearn-sb
Copy link

ben-hearn-sb commented Aug 31, 2023

Hello!

I had a strange issue with the built plugins for MySql on your page, they worked for a time and then they just stopped for some reason and I have not been able to get them operating again.

I have switched over to PySide6 (6.5.2) and downloaded the latest built plugin (6.5.2) and followed the answer at the bottom on this Stackoverflow page to the letter: https://stackoverflow.com/questions/64056483/unable-to-load-qmysql-driver-on-pyside2

Nothing works... Do you have any suggestion before I move my entire database module over to postgres, psycopg2 and construct the QTable by hand?

This is the output of my launching of the database connection (pretty common for sure but impossible to fix):

QMARIADB
QMYSQL
QSQLITE
QODBC
QPSQL
Failure to open database. Fatal error
<PySide6.QtSql.QSqlError("", "Driver not loaded", "Driver not loaded") at 0x00000254539F6FC0>
@thecodemonkey86
Copy link
Owner

Hi,
is there any additional output if you set the QT_DEBUG_PLUGINS=1 environment variable that might be helpful? Did you check all dependencies of qsqlmysql.dll by using e.g. https://github.com/lucasg/Dependencies ?

@ben-hearn-sb
Copy link
Author

I found your quick fix solution on this issue: #24

This quick fix seems to resolve the drivers not loaded errors. Is there a solution that allows for relative pathing inside a custom package or some such?

I have tried
os.environ['PATH']
os.environ['PYTHONPATH']
os.add_dll_directory()

Unfortunately nothing has worked so far :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants