You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was also having this issue. I found that the reference to DATABASE_CLASS should be the following (notice the case of the class name). DatastoreMySQL should be DatastoreMysql
I found the answer by trying to import the module and seeing what VS Code intellisense came up with. Not sure why I need to do this? I am using the version from PyPi which is 0.3.0 - is this not the latest version?
Update: Looks like file was deleted then added again with a different case for MySQL. This is the committ..
When I override DB setting, I got error. See below
settings.py
DATABASE_CLASS = 'ndscheduler.core.datastore.providers.mysql.DatastoreMySQL' DATABASE_CONFIG_DICT = { 'user': 'username', 'password': '', 'hostname': 'localhost', 'port': 3306, 'database': 'scheduler' }
Error
app_1 | Traceback (most recent call last): app_1 | File "scheduler.py", line 46, in <module> app_1 | SampleJobServer.run() app_1 | File "/usr/local/lib/python3.6/site-packages/ndscheduler/server/server.py", line 83, in run app_1 | cls.singleton = cls(scheduler_manager.SchedulerManager.get_instance()) app_1 | File "/usr/local/lib/python3.6/site-packages/ndscheduler/core/scheduler_manager.py", line 22, in get_instance app_1 | cls.instance = cls() app_1 | File "/usr/local/lib/python3.6/site-packages/ndscheduler/core/scheduler_manager.py", line 27, in __init__ app_1 | 'default': utils.get_datastore_instance() app_1 | File "/usr/local/lib/python3.6/site-packages/ndscheduler/utils.py", line 106, in get_datastore_instance app_1 | database_class = import_from_path(settings.DATABASE_CLASS) app_1 | File "/usr/local/lib/python3.6/site-packages/ndscheduler/utils.py", line 31, in import_from_path app_1 | return getattr(module, components[-1]) app_1 | AttributeError: module 'ndscheduler.core.datastore.providers.mysql' has no attribute 'DatastoreMySQL'
The text was updated successfully, but these errors were encountered: