# ROOT 6.23 changing name of branch with TClonesArray

**URL:** <https://root-forum.cern.ch/t/root-6-23-changing-name-of-branch-with-tclonesarray/43626>\
**Category:** Newbie\
**Created:** [February 20, 2021, 11:27am UTC](https://root-forum.cern.ch/t/root-6-23-changing-name-of-branch-with-tclonesarray/43626 "2021-02-20T11:27:53Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![antonio.iuliano2](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/antonio.iuliano2/32/24948_2.png) [@antonio.iuliano2](https://root-forum.cern.ch/u/antonio.iuliano2)\
**Post date:** [February 20, 2021, 11:27am UTC](https://root-forum.cern.ch/t/root-6-23-changing-name-of-branch-with-tclonesarray/43626/1 "2021-02-20T11:27:54Z")

</div>

_ROOT Version:_ 6.23.01 (compared with 6.18/00 and 6.22/02)  
_Platform:_ CentOS Linux release 7.9.2009 (lxplus)  
_Compiler:_ Not Provided

* * *

Dear ROOT experts,

I have noticed a weird behaviour of ROOT 6.23/01 in TTree I/O. Let us assume I have a branch called “t.”, referring to a TClonesArray of a class “Event”. Previous versions of ROOT always store the TTree with branches having the following name structure:

t. (for the class)  
t…e (for a member of the class)

When I stored a TTree with this newer ROOT version, instead the branch naming convention changes, removing the dot:

t (for the class)  
t.e (for a member of the class)

You can find an example code here (modified from the ROOT tutorial tree0.C, but using a TClonesArray) and the output I obtain in different ROOT versions.

My question is if this change is intentionally done, since the branches ending with the dot give issues with PyROOT. In this case, could you please add a warning when you tell the user of this branch name change?

Best regards,  
Antonio

[testtree\_61800.root](https://root-forum.cern.ch/uploads/short-url/oxFODaVGi2GjSBtUE2GPEv2Jvrt.root) (178.5 KB) [testtree\_62301.root](https://root-forum.cern.ch/uploads/short-url/5CnjEkgDh3Dn1WjeaW7Gd0lgx0X.root) (178.8 KB) [testtree\_62202.root](https://root-forum.cern.ch/uploads/short-url/zVF7DdKEevJwMIWoo2kLdZMOBtT.root) (178.5 KB) [tree0.C](https://root-forum.cern.ch/uploads/short-url/hVwZusHkPz2yqiRq3Cyb3hr5Q3k.C) (2.0 KB)

---

<div class="post-metadata">

**Author:** ![pcanal](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/pcanal/32/12439_2.png) [@pcanal](https://root-forum.cern.ch/u/pcanal)\
**Post date:** [February 22, 2021, 11:00pm UTC](https://root-forum.cern.ch/t/root-6-23-changing-name-of-branch-with-tclonesarray/43626/2 "2021-02-22T23:00:24Z")

</div>

> [@antonio.iuliano2](#):
>
> since the branches ending with the dot give issues with PyROOT. I

So the change sounds like an improvement isn’t it? In addition it avoid the confusing double consecutive dot in the subbranch name.

What is the practical (negative) consequence in your case?

And yes, the change is intentional and need to be mentioned in the release notes of v6.24.

---

<div class="post-metadata">

**Author:** ![antonio.iuliano2](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/antonio.iuliano2/32/24948_2.png) [@antonio.iuliano2](https://root-forum.cern.ch/u/antonio.iuliano2)\
**Post date:** [February 24, 2021, 12:26pm UTC](https://root-forum.cern.ch/t/root-6-23-changing-name-of-branch-with-tclonesarray/43626/3 "2021-02-24T12:26:30Z")

</div>

Thank you very much for your answer.

The only negative consequence I can think of is that code reading the branch needs to be modified to correctly set the branch address (I originally discovered the issue since my code did not find the branch anymore).

I mostly wanted confirmation of this behaviour.

Best regards,  
Antonio

---

<div class="post-metadata">

**Author:** ![pcanal](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/pcanal/32/12439_2.png) [@pcanal](https://root-forum.cern.ch/u/pcanal)\
**Post date:** [February 24, 2021, 1:20pm UTC](https://root-forum.cern.ch/t/root-6-23-changing-name-of-branch-with-tclonesarray/43626/4 "2021-02-24T13:20:40Z")

</div>

Hi Antonio,

I see the behavior difference and it was not expected. So it look like the intent was to remove the double dot in the sub-branches but not the trailing dot in the top level branch. We need to update this before the release (i.e. no user code change when accessing the top level branch was intended ☹ )

Thanks for the report.  
Philippe.

---

<div class="post-metadata">

**Author:** ![pcanal](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/pcanal/32/12439_2.png) [@pcanal](https://root-forum.cern.ch/u/pcanal)\
**Post date:** [April 13, 2021, 1:22am UTC](https://root-forum.cern.ch/t/root-6-23-changing-name-of-branch-with-tclonesarray/43626/5 "2021-04-13T01:22:52Z")

</div>

This is fixed by [Redo part of 'Correct FullName of the index leaf of a collection' by pcanal · Pull Request #7843 · root-project/root · GitHub](https://github.com/root-project/root/pull/7843)

---

<div class="post-metadata">

**Author:** ![antonio.iuliano2](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/antonio.iuliano2/32/24948_2.png) [@antonio.iuliano2](https://root-forum.cern.ch/u/antonio.iuliano2)\
**Post date:** [April 13, 2021, 11:43am UTC](https://root-forum.cern.ch/t/root-6-23-changing-name-of-branch-with-tclonesarray/43626/6 "2021-04-13T11:43:43Z")

</div>

Dear Philippe,

thank you for the update.

Best regards,  
Antonio
