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
Whenever a ConfigPath object is accessed, the validate function is called which in turn asks the user whether the path should be created if missing. This is makes it very annoying to use inside containers or when running benchbuild via slurm since we cannot always guarantee that all paths exist beforehand. It would be nice to have a mechanism that allows us to temporarily disable the user query or, at least, give us a way to create these paths without any user input (e.g., similar to how you handle tests or the CI).
The text was updated successfully, but these errors were encountered:
Sorry for the delay. I did not have access to github during vacation.
The ConfigPath should be "auto-created" whenever there is no tty attached to the parent process. If this check fails, you can "cheat" by defining CI=yes as env var.
The check itself is pretty basic and relies on Python's sys.stdin module:
ignore_stdin_istty = should_ignore_tty()
has_tty = sys.stdin.isatty() and not ignore_stdin_istty
The ignore_stdin_istty handles CI=yes or unittesting (TEST=yes)
The check should not fail when benchbuild is running inside SLURM. I have no idea, if somewhere withing SLURM -> OCI Container a stdin gets attached somewhere. It might be the case.
I could provide a CLI option or BB-style envvar for the settings to control the ignore stdin_istty setting, if that is sufficient.
Yeah, there seems to be some sort of wiredness going on in that regard.
Anyway, we now opted for simply not using ConfigPath anywhere. This works out for us since we kind of self-manage our benchbuild config anyway.
Whenever a
ConfigPath
object is accessed, thevalidate
function is called which in turn asks the user whether the path should be created if missing. This is makes it very annoying to use inside containers or when running benchbuild via slurm since we cannot always guarantee that all paths exist beforehand. It would be nice to have a mechanism that allows us to temporarily disable the user query or, at least, give us a way to create these paths without any user input (e.g., similar to how you handle tests or the CI).The text was updated successfully, but these errors were encountered: