Message10544
First of all, thanks for maintaining this great project!
On Jython 2.7.0:
I have a weird behaviour using Bytes class in hbase-common-1.0.0-cdh5.4.5.jar.
>>> qualifier
array('b', [98, 121, 116, 101, 45, 115, 105, 122, 101])
>>> Bytes.toString(qualifier)
u'[B@30f88a41'
>>> Bytes.toString(qualifier, 0, len(qualifier))
u'byte-size'
>>> Bytes.toString(str(qualifier))
u"array('b', [98, 121, 116, 101, 45, 115, 105, 122, 101])"
>>> Bytes.toString(repr(qualifier))
u"array('b', [98, 121, 116, 101, 45, 115, 105, 122, 101])"
The correct result is 'byte-size', the issue is the '[B@30f88a41' result.
Documentation in http://archive.cloudera.com/cdh5/cdh/5/hbase-1.0.0-cdh5.4.5/apidocs/index.html
Another thing, if I call:
>>> Bytes.toBytes('v')
The toBytes(String) implementation is called,
however the documentation at: https://wiki.python.org/jython/UserGuide#id13
seem's to say that 'v' should be coerced into a char thus call the toBytes(int) implementation.
TBH I rely on this 'v' coercion to string so that's not really an issue
but I wonder when coercion into char happens and if the doc should be updated.
Thanks for taking a look, |
|
Date |
User |
Action |
Args |
2015-12-17 11:49:46 | lsenta | set | recipients:
+ lsenta |
2015-12-17 11:49:46 | lsenta | set | messageid: <1450352986.1.0.818457690885.issue2444@psf.upfronthosting.co.za> |
2015-12-17 11:49:46 | lsenta | link | issue2444 messages |
2015-12-17 11:49:44 | lsenta | create | |
|