While trying to run a Murfey server locally, I noticed that the existing visits weren't displaying correctly. Upon further investigation, I have narrowed it down to this code block:
|
try: |
|
Session = sqlalchemy.orm.sessionmaker( |
|
bind=sqlalchemy.create_engine(url(), connect_args={"use_pure": True}) |
|
) |
|
except AttributeError: |
|
Session = lambda: None |
When the ISPYB_CREDENTIALS environment variable is not set, the database fails to load. It looks like the ISPyB credentials that we are providing as part of the security configuration file aren't being taken into account.
Ideally, this request to load the database should make use of the ISPyB credentials provided in the security configuration file.