JetRecConfig: Safely unlock clonable children only
A rather nasty side-effect of the @clonable decorator used in JetRecConfig was leading to a situation where JetDefinition.clone() could unlock AthConfigFlags, which were held as a data member. The unlock of children should only be applied to other @clonable instances rather than anything under the sun.
For this to go wrong required a particular coincidence where:
- I added a custom
JetDefinition.__deepcopy__()that would not clone a new instance of the_cflagsmember - I was more scrupulous than usual about locking
JetDefinitioninstances, leading to the built inclone()calls elsewhere performing the unlock
Discovering it required one more feature which was to call a function with @AccumulatorCache after the unlock happened, which would break on attempting to hash the unlocked flag container.
This fix is needed to make !70788 (merged) work safely and efficiently.