labscript-suite / blacs

𝗯𝗹𝗮𝗰𝘀 supervises the execution of experiments controlled by the 𝘭𝘢𝘣𝘴𝘤𝘳𝘪𝘱𝘵 𝘴𝘶𝘪𝘵𝘦. It manages experiment queuing and hardware-timed execution, and provides manual control over devices between shots.
http://labscriptsuite.org
Other
4 stars 48 forks source link

Move config path to same location as other apps #68

Closed chrisjbillington closed 4 years ago

chrisjbillington commented 4 years ago

And have it named BLACS.h5 instead of containing the hostname.

This ensures we don't use variables no longer defined in labscript_utils.labconfig as of labscript-suite/labscript-utils#45, whilst also conforming to a more standard layout of where the config file is stored.

A nice side effect of storing the BLACS config in the app_saved_configs dir is that if the user changes the experiment name in their labconfig file, they can switch between BLACS configs from different experiments without having to recompile the connection table, change globals files in BLACS, etc. So different experiments on the same machine can have a more self-contained config.

I don't see much upside to keeping the hostname in the config filename, so now it's just BLACS.h5. With labconfig there is at least the idea that you might version control the labconfig directory to share changes between computers, but that is not as useful for BLACS' config.

chrisjbillington commented 4 years ago

Moving and renaming your BLACS config should be documented in migration notes.

philipstarkey commented 4 years ago

I have some objections to the removal of the hostname from the BLACS settings file under the assumption it is never version controlled. Monash labs do version control this. Obviously it's binary, so you can't diff it, but it's a convenient way to keep a backup of the preferences which can be a pain to reconfigure from scratch. With the eventual plan to be able to launch secondary copies of BLACS on other PCs, hostnames become important to distinguish settings files.

The BLACS settings file really needs a bigger overhaul, so I would suggest a minimum of changes so that we don't have to ask users to go through this again.

chrisjbillington commented 4 years ago

I can put it back in easily enough - though with this change since it is in a subdirectory named after the experiment (as are all app configs), it still has a unique path. So it's still good for version control at the moment, but maybe not for multiple config files for the same experiment that refer to different computers.

How about moving it but putting the hostname back in (preserving the same filename as before this change)? If so, I'll add the hostname variable back into the labconfig module.

philipstarkey commented 4 years ago

Yeah, I don't mind moving the location. Although, where is the app_saved_configs dir now? Is it in the profile directory?

chrisjbillington commented 4 years ago

Yep, at the top level. But configurable in labconfig.