You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With a compiled code everything works as expected:
root -l
root [0] .L test.cpp+
root [1] test()
gives correct output:
aaaa bbbbbb cccc
aaaa bbbbbb cccc
But if I try to read again the same file:
root -l test.root
root [0] gSystem->Load("test_cpp")
root [1] obj->Print()
Error in <TBufferFile::ReadVersion>: Could not find the StreamerInfo with a checksum of 0x6b3ba626 for the class "string" in test.root.
Error in <TBufferFile::CheckByteCount>: object of class string read too many bytes: 72 instead of 24
Warning in <TBufferFile::CheckByteCount>: string::Streamer() not in sync with data on file test.root, fix Streamer()
aaaabbbbbb@ cccc�i�� cccc
With an older version of ROOT (6.18), everything works as expected.
Some additional information
I tried to compare StreamerInfo for 2 ROOT versions and they are different (last item):
root 6.18
root [2] _file0->ShowStreamerInfo()
OBJ: TList TList Doubly linked list : 0
StreamerInfo for class: TestClass, version=1, checksum=0x84f55819
TObject BASE offset= 0 type=66 Basic ROOT object
map<array<string,2>,string> test_map_ offset= 0 type=300 (nodelete) ,stl=4, ctype=61,
StreamerInfo for class: pair<array<string,2>,string>, version=1, checksum=0x64321048
string first [2] offset= 0 type=320 ,stl=365, ctype=365,
string second offset= 0 type=300 ,stl=365, ctype=365,
root 6.22,24
root [3] _file0->ShowStreamerInfo()
OBJ: TList TList Doubly linked list : 0
StreamerInfo for class: TestClass, version=1, checksum=0x84f55819
TObject BASE offset= 0 type=66 Basic ROOT object
map<array<string,2>,string> test_map_ offset= 0 type=300 (nodelete) ,stl=4, ctype=61,
StreamerInfo for class: pair<array<string,2>,string>, version=1, checksum=0xb5fb752
array<string,2> first offset= 0 type=62 Emulation
string second offset= 0 type=300 ,stl=365, ctype=365, Emulation
StreamerInfo for class: array<string,2>, version=1, checksum=0x6b3ba626
string _M_elems offset= 0 type=320 ,stl=365, ctype=365
Unfortunately, I don't how to proceed further.
Setup
Reproduced with ROOT 6.22.08, 6.24 (today's version from the branch with patches)
Operating system Fedora 33 / centos7
binary download / you built it yourself.
The text was updated successfully, but these errors were encountered:
Describe the bug
Error reading object from file. Please find a short example to reproduce below.
Minimal example to reproduce
Below I refer to it as test.cpp
Running the example
With a compiled code everything works as expected:
gives correct output:
But if I try to read again the same file:
With an older version of ROOT (6.18), everything works as expected.
Some additional information
I tried to compare StreamerInfo for 2 ROOT versions and they are different (last item):
root 6.18
root 6.22,24
Unfortunately, I don't how to proceed further.
Setup
The text was updated successfully, but these errors were encountered: