Hi,
When changing from ROOT 5.16 to 5.20 I get now some errors I didn’t get before.
I produced a short example macro:
{
Int_t a, b, c;
TTree *t = new TTree( "aname", "atitle" );
t->Branch( "var_a", &a, "var_a/I" );
t->Branch( "var_b", &b, "var_b/I" );
t->Branch( "var_c", &c, "var_c/I" );
for( int i=0; i<10; i++ ){
a = i;
b = i*2;
c = i*4;
t->Fill();
}
t->Print();
TFile *f = TFile::Open( "mytestfile.root", "RECREATE" );
t->Write();
f->Close();
}
This code produces in ROOT 5.16 the following output:
root [0]
Processing mytester.C...
******************************************************************************
*Tree :aname : atitle *
*Entries : 10 : Total = 2259 bytes File Size = 0 *
* : : Tree compression factor = 1.00 *
******************************************************************************
*Br 0 :var_a : var_a/I *
*Entries : 10 : Total Size= 668 bytes One basket in memory *
*Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 *
*............................................................................*
*Br 1 :var_b : var_b/I *
*Entries : 10 : Total Size= 668 bytes One basket in memory *
*Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 *
*............................................................................*
*Br 2 :var_c : var_c/I *
*Entries : 10 : Total Size= 668 bytes One basket in memory *
*Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 *
*............................................................................*
root [1] .q
but in ROOT 5.20 I get additionally some errors when writing the TTree to a file:
root [0]
Processing mytester.C...
******************************************************************************
*Tree :aname : atitle *
*Entries : 10 : Total = 2283 bytes File Size = 0 *
* : : Tree compression factor = 1.00 *
******************************************************************************
*Br 0 :var_a : var_a/I *
*Entries : 10 : Total Size= 676 bytes One basket in memory *
*Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 *
*............................................................................*
*Br 1 :var_b : var_b/I *
*Entries : 10 : Total Size= 676 bytes One basket in memory *
*Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 *
*............................................................................*
*Br 2 :var_c : var_c/I *
*Entries : 10 : Total Size= 676 bytes One basket in memory *
*Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 *
*............................................................................*
Error in <TBasket::Create>: Cannot create key without file
Error in <TBasket::Create>: Cannot create key without file
Error in <TBasket::Create>: Cannot create key without file
root [1] .q
Can you point me to the error I made or what I have to change when moving to 5.20 respectively.
Thanks,
Peter