-
Notifications
You must be signed in to change notification settings - Fork 109
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
[feat] Build configuration incrementally by allowing to combine multiple configuration files #2557
Conversation
…feat/configuration_scopes
…feat/configuration_scopes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We also need a unit test to explicitly test the update_config()
(your add_config()
currently) as well as to update the docs. Also regarding the order that the various sections are combined we should be careful, since in several places in the code we assume the place 0 as the "default", since we don't expect to have another entry (see for example general/0/option-x
). I've seen that you had tweak the unit tests to pass specifically for this and this can be dangerous. Perhaps we need place 0 to be the latest, but we must have a look at it more thoroughly. Playing with the --show-config
option should help with this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we need to focus a bit more on how we intend to use this feature.
…feat/configuration_scopes
Regarding the usage of this feature, I was thinking the following:
@ekouts @victorusu What do you think? |
|
|
@victorusu about (1) I think @vkarak suggests to keep |
I would say no and just use directories with
That's easy; we simply look for a specific config file pattern that includes the system name, e.g.,
For your first part of the question, the answer is yes. We will put those in the path. For the second, the user only needs to do
I cannot understand this very well. |
I am a bit puzzled of what is the best for the default behaviour of the |
I agree that Having said that, I am not sure if the
Is it ok? |
The person who wrote this (👆) doesn't know how to write in English... Sorry for that... The correct spelling is the following...
I agree that Having said that, I am not sure if the
Is it ok? What do you think? |
If we say that the |
- Update the docs based on the new configuration capabilities - Minimize the use of rfmdocstart/end annotations
@ekouts could you rerun the doc listings on Daint? I have changed substantially the way the configuration is presented and we'd need to rerun. |
@jenkins-cscs retry all |
I cannot approve because I am the original author, but ltgm |
The configs that showcase the `resources` and the `container_platforms` are made minimal redefining only Daint. With the new configuration mechanism, these configs are still valid if combined with the baseline `daint.py`.
@vkarak looks good to me. |
This PR introduces some changes for the configuration:
generic
system (local scheduler and launcher) and thebuiltin
environment. It also includes the basic logging handler and handlers_perflogEDIT @vkarak: This PR also adds and changes the following:
We warn on system, partition and environment redefinitions
All sections with unnamed objects are merged and resolved based on the
selected system. As a result, this sections can be combined arbitrarily through
as the chain of configuration files is loaded and the resulting internal config
will always has a single such object, so that it is guaranteed that calls, such
as
get('general/0/<option>')
will always yield the correct value.Add a special section named
handlers$
that contains the basic stream handlerthat handles the framework's output. This allows users to override the
standard
handlers
without having to override the basic output handler.Only a single stdout and stderr stream handler is considered and if a second
one is defined this is silently ignored. This was done primarily for
backward compatibility with the current user configurations, so that their
framework stdout handler in
handlers
will be simply ignored in favor of theone in the special section
handlers$
.Unit tests were updated and cleaned up.
Will close #1725 .
Todos