• Jason Madden's avatar
    [ZEO4] Use pickle protocol 3 on the wire. · 0070105f
    Jason Madden authored
    ( Upstream commit 1b21b3a8 )
    
    --------
    
    Kirr: wendelin.core 2 switched to using pickle protocol=3 on its go side
    completely in neo@1bb0eb24
    ( neo!8 ). It all works with
    ZODB5/ZEO5 on both py2 and py3, but without this backport ZEO/go driver
    started to fail without being able to connect to ZEO4/py server:
    
        (neo) (z4-dev) (g.env) kirr@deca:~/src/neo/src/lab.nexedi.com/kirr/neo/go/zodb/storage/zeo$ go test -v -failfast
        ...
        === RUN   TestEmptyDB/msgpack=false/py2
        ------
        2025-02-28T13:34:59 INFO ZEO.runzeo (1979570) opening storage '1' using FileStorage
        ------
        2025-02-28T13:34:59 INFO ZEO.StorageServer StorageServer created RW with storages: 1:RW:/tmp/zeo1011468807/1.fs
        ------
        2025-02-28T13:34:59 INFO ZEO.zrpc (1979570) listening on /tmp/zeo1011468807/1.fs.zeosock
        ------
        2025-02-28T13:34:59 INFO ZEO.zrpc.Connection('S') () received handshake 'Z4'
        ------
        2025-02-28T13:34:59 ERROR ZEO.zrpc (1979570) can't decode message: '\x80\x03(K\x00K\x00X\x08\x00\x00\x00registerX\x01\x00\x...'
        ------
        2025-02-28T13:34:59 ERROR ZEO.zrpc.Connection('S') () Error caught in asyncore
        Traceback (most recent call last):
          File "/usr/lib/python2.7/asyncore.py", line 83, in read
            obj.handle_read_event()
          File "/usr/lib/python2.7/asyncore.py", line 449, in handle_read_event
            self.handle_read()
          File "/home/kirr/src/wendelin/z/ZEO4/src/ZEO/zrpc/smac.py", line 243, in handle_read
            self.message_input(msg)
          File "/home/kirr/src/wendelin/z/ZEO4/src/ZEO/zrpc/connection.py", line 421, in message_input
            msgid, async, name, args = self.decode(message)
          File "/home/kirr/src/wendelin/z/ZEO4/src/ZEO/zrpc/marshal.py", line 98, in server_decode
            return unpickler.load() # msgid, flags, name, args
        ValueError: unsupported pickle protocol: 3
    
    As support for ZODB4 is scheduled to be phased out it is easier to make
    ZEO4 backport instead of adding more runtime detection and compatibility
    code to ZEO/go.
    0070105f
To find the state of this project's repository at the time of any of these versions, check out the tags.
CHANGES.rst 2.48 KB