-
Notifications
You must be signed in to change notification settings - Fork 58
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
Startup Project does not list same projects as the Projects tab #1074
Comments
I'll check this in the coming week/s, just a quick question, as I have a suspicion that this is due to the reading of the settings file, was this all in one session with the AB? If you close and reload the AB do the listed projects match? |
It does not change if the AB is closed and reopened... there is simply a mismatch between the two and what the AB settings reads is not up to date, so there the call is probably wrong... |
I think this is caused by the following function:
This function actually reads the Brightway dir (in your case
What I propose is that we move |
If I understand your sollution correctly @marc-vdm your sollution would lead to the startup project list not updating when a new brightway dir is selected as the ProjectController is only updated after hitting save in the settings wizard. I'd suggest updating self.bw_projects(path) to read the projects from the db file in said path directly. Like so: def bw_projects(self, path: str):
""" Read the bw_projects from the brightway2 environment provided by path"""
db = SqliteDatabase(os.path.join(path, "projects.db"))
cursor = db.execute_sql('SELECT "name" FROM "projectdataset"')
return [ i[0] for i in cursor.fetchall()] Also see the commit above |
* Settings Wizard read Projects from Database #1074 * Fixed unsafe path * Added comments
Note This issue has been implemented in the new release of Activity Browser 🚀 (version 2.9.4), you can get the new version by updating Activity Browser. Do you want to be notified of new releases of Activity Browser? Subscribe to our updates mailing list ✉. 🤖_beep boop! I'm a bot and this message was an automated action._ |
Updating AB
What happened?
When trying to set a recent project as the "startup project" in settings, I notice that the list of projects there is different and does not include the projects I recently created.
List in Projects
List in Settings > Startup Project:
Relevant errors
No response
Operating system
Windows 10
Conda environment
No response
The text was updated successfully, but these errors were encountered: