Skip to content
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

Not possible to set Algorithm.OutputLevel from commandline? #211

Open
Zehvogel opened this issue Jul 16, 2024 · 3 comments
Open

Not possible to set Algorithm.OutputLevel from commandline? #211

Zehvogel opened this issue Jul 16, 2024 · 3 comments

Comments

@Zehvogel
Copy link
Contributor

Or at least I am too stupid to figure out the correct syntax, but when I try something like

k4run mysteeringfile.py --MyAlgorithm.OutputLevel=ERROR

I only get a

k4run: error: argument --MyAlgorithm.OutputLevel/--OutputLevel.MyAlgorithm: invalid int value: 'ERROR'
@tmadlener
Copy link
Contributor

You would need to convert ERROR to an integer for this to work, which in turn would probably require some custom arg parsing logic. It could make sense to do that for the OutputLevel, but I am not sure about all properties.

@jmcarcell
Copy link
Member

jmcarcell commented Jul 16, 2024

Here you have the constants, thanks for the PR @Zehvogel!!!!
https://gitlab.cern.ch/gaudi/Gaudi/-/blob/master/GaudiKernel/python/GaudiKernel/Constants.py#L28

As a workaround you can pass the integer value and that will work, like

k4run mysteeringfile.py --MyAlgorithm.OutputLevel 5

@Zehvogel
Copy link
Contributor Author

Thx for the workaround :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants