-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Introduce toReplaceWith()-equivalent to EDModules/Sequences/Paths themselves? #15425
Comments
A new Issue was created by @makortel Matti Kortelainen. @davidlange6, @smuzaffar, @Dr15Jones can you please review it and eventually sign/assign? Thanks. cms-bot commands are listed here |
assign core |
New categories assigned: core @Dr15Jones,@smuzaffar you have been requested to review this Pull request/Issue and eventually sign? Thanks |
@Dr15Jones , @makortel , do we still need this or was it already implemented? |
It has not been implemented, in principle it could be useful. On the other hand there is cmssw/HLTrigger/Configuration/python/common.py Lines 59 to 61 in b221493
|
Now that we have some experience of eras (
cms.Modifier
) withtoReplaceWith()
andtoModify()
, I'd like to suggest to addtoReplaceWith()
mechanism to the EDModules/Sequences/(End)Paths directly (probably named as e.g.replaceWith()
as the action can and should be taken immediately).This would be useful for the remaining use-cases of customize functions (e.g. test recipes or HLTrigger/Configuration/python/customizeHLTforCMSSW.py) when one needs to replace a module with another in all Sequences while keeping the label. Currently the same effect can be achieved with
I'm already using this pattern in Validation/RecoTrack/python/customiseTrackingNtuple.py#L16 (for EndPath), but I'll soon (~week) have another case for EDProducers in
customizeHLTforCMSSW.py
.Note that I can live with the use of
Modifier
as above (the need is not that frequent, and it is already much simpler than the "old way" of first removing the module from all sequences, replacing the module, and re-inserting to all sequences), but I though to raise the question in case the mechanism would have wider interest.If
replaceWith()
gets accepted, I'd suggest to consider adding alsomodify()
for EDModules on the same go (for consistency).@Dr15Jones
The text was updated successfully, but these errors were encountered: