core: Fix unicode bug on ZODB History view.
Some objects, in our case BTrees.Length.Length in a ZODB connection have a __str__ method that returns unicode on python2: u'<BTrees.Length.Length object at 0x7f850932e0d0 oid 0x1e334 in <Connection at 7f854bc0f190>>' They cause an unicode error in the history view when they are concatenated together with other str (encoded as UTF-8) properties, this can be observed when using history view with a "folderish" document (but not with a File as in test_ZODBHistoryBinaryData). To prevent this issue, we use the fact that ''.format unlike '' % seem to apply a str() on arguments and use it instead. Co-authored-by: Yusei Tahara <yusei@nexedi.com>
Status | Job ID | Name | Coverage | ||||||
---|---|---|---|---|---|---|---|---|---|
External | |||||||||
passed |
#528614
external
|
ERP5.CodingStyleTest-Master |
00:35:10
|
||||||
passed |
#528652
external
|
ERP5.PerformanceTest-Master |
00:27:28
|
||||||
failed |
#528623
external
|
ERP5.UnitTest-Master |
01:17:00
|
||||||
failed |
#528633
external
|
ERP5.UnitTest-Master.Medusa |
01:19:00
|
||||||
passed |
#528624
external
|
SlapOS.Eggs.UnitTest-Master.Python2 |
00:11:39
|
||||||
passed |
#528640
external
|
SlapOS.Eggs.UnitTest-Master.Python3 |
00:12:50
|
||||||