<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/python-packages/pymemcache.git/pymemcache/test/test_serde.py, branch github-actions</title>
<subtitle>github.com: pinterest/pymemcache.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/'/>
<entry>
<title>Change serialization interface to be an object (#245)</title>
<updated>2019-08-26T18:11:31+00:00</updated>
<author>
<name>Stephen Rosen</name>
<email>sirosen@globus.org</email>
</author>
<published>2019-08-26T18:11:31+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/commit/?id=5699c9dfa7067a99000e281091dd6400a1e84122'/>
<id>5699c9dfa7067a99000e281091dd6400a1e84122</id>
<content type='text'>
* Change serialization interface to be an object

Rather than passing separate serialization and deserialization methods
to a pymemcache client, pass an object implementing a very simple
two-method interface.

This is a rather significant breaking change and should be part of an
x.0.0 major release.

Resolves #56

As suggested in that issue, this is a cleaner interface, as there's no
sensible context in which you would provide only one of these two
methods and it should therefore be thought of as a
serialization/deserialization protocol.

Also adds a note to the documentation's Best Practices list that you
should use the built-in serializer object unless you have a reason to do
otherwise.

* Support "de/serializer" in addition to "serde"

In order to support older client usage in addition to the new
serialization object (protocol), restore the "serializer" and
"deserializer" arguments to the Client classes.
These are marked as deprecated and will be automatically wrapped into a
small "serde" object.

In order to make the various object names more distinguishable and more
informative, the built-in default serializer is now called
"python_memcache_pickle_serde"

Additionally, default client.serde to a "no-op serializer".
This object does no transforms on the data. By putting this in place, we
can skip some conditionals in the code around presence or absence of a
serializer and therefore simplify internally (at the cost of an extra,
unnecessary, functional call in some cases).

It also simplifies logic around the handling of flags because we are now
*guaranteed* the presence of a serializer object which returns some
flags. i.e. "default flags" are no longer the responsibility of the
various serializer usage sites.
This is done carefully to ensure that passing a `serializer` without a
`deserializer` is respected.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Change serialization interface to be an object

Rather than passing separate serialization and deserialization methods
to a pymemcache client, pass an object implementing a very simple
two-method interface.

This is a rather significant breaking change and should be part of an
x.0.0 major release.

Resolves #56

As suggested in that issue, this is a cleaner interface, as there's no
sensible context in which you would provide only one of these two
methods and it should therefore be thought of as a
serialization/deserialization protocol.

Also adds a note to the documentation's Best Practices list that you
should use the built-in serializer object unless you have a reason to do
otherwise.

* Support "de/serializer" in addition to "serde"

In order to support older client usage in addition to the new
serialization object (protocol), restore the "serializer" and
"deserializer" arguments to the Client classes.
These are marked as deprecated and will be automatically wrapped into a
small "serde" object.

In order to make the various object names more distinguishable and more
informative, the built-in default serializer is now called
"python_memcache_pickle_serde"

Additionally, default client.serde to a "no-op serializer".
This object does no transforms on the data. By putting this in place, we
can skip some conditionals in the code around presence or absence of a
serializer and therefore simplify internally (at the cost of an extra,
unnecessary, functional call in some cases).

It also simplifies logic around the handling of flags because we are now
*guaranteed* the presence of a serializer object which returns some
flags. i.e. "default flags" are no longer the responsibility of the
various serializer usage sites.
This is done carefully to ensure that passing a `serializer` without a
`deserializer` is respected.</pre>
</div>
</content>
</entry>
<entry>
<title>Make pickle version for python_memcache_serializer adjustable</title>
<updated>2018-09-07T22:55:14+00:00</updated>
<author>
<name>Joe Gordon</name>
<email>jogo@pinterest.com</email>
</author>
<published>2018-09-07T21:52:43+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/commit/?id=c9b89dcef88cf94b22da7c9ad80b3212a15233b5'/>
<id>c9b89dcef88cf94b22da7c9ad80b3212a15233b5</id>
<content type='text'>
It's unsafe to use the max pickle version when you are switching between
versions of python with different max versions.

Add a new function get_python_memcache_serializer that
returns a python_memcache_serializer with any pickle version.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It's unsafe to use the max pickle version when you are switching between
versions of python with different max versions.

Add a new function get_python_memcache_serializer that
returns a python_memcache_serializer with any pickle version.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add FLAG_BYTES</title>
<updated>2016-12-04T23:15:37+00:00</updated>
<author>
<name>Alex Tomkins</name>
<email>tomkins@darkzone.net</email>
</author>
<published>2016-11-22T23:53:10+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/commit/?id=be8977c61d1cd1d488d81d94f0097103a7726fe5'/>
<id>be8977c61d1cd1d488d81d94f0097103a7726fe5</id>
<content type='text'>
Unused in serde itself (it's a default), but used for testing comparisons
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Unused in serde itself (it's a default), but used for testing comparisons
</pre>
</div>
</content>
</entry>
<entry>
<title>Add more serde unit tests for bytes/unicode</title>
<updated>2016-12-04T23:15:37+00:00</updated>
<author>
<name>Alex Tomkins</name>
<email>tomkins@darkzone.net</email>
</author>
<published>2016-11-22T23:49:01+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/commit/?id=ea84e3347c4255badc5bb93e2d6d6caff4313cbf'/>
<id>ea84e3347c4255badc5bb93e2d6d6caff4313cbf</id>
<content type='text'>
Use some common characters
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use some common characters
</pre>
</div>
</content>
</entry>
<entry>
<title>Add test for subclasses of builtin types</title>
<updated>2016-12-04T23:15:37+00:00</updated>
<author>
<name>Alex Tomkins</name>
<email>tomkins@darkzone.net</email>
</author>
<published>2016-11-13T23:10:24+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/commit/?id=1c565fb472c07dffcf95f925b647f17f3e86aa43'/>
<id>1c565fb472c07dffcf95f925b647f17f3e86aa43</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Test for expected flags with serde tests</title>
<updated>2016-12-04T23:15:37+00:00</updated>
<author>
<name>Alex Tomkins</name>
<email>tomkins@darkzone.net</email>
</author>
<published>2016-11-13T23:02:05+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/commit/?id=7f611e99d36089bc6836042ba8aec2df02a56f3a'/>
<id>7f611e99d36089bc6836042ba8aec2df02a56f3a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Use byte strings after serializing with serde</title>
<updated>2016-12-04T23:15:37+00:00</updated>
<author>
<name>Alex Tomkins</name>
<email>tomkins@darkzone.net</email>
</author>
<published>2016-11-13T16:46:17+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/commit/?id=b6c8921b7281f24f5e8353cd0542d7ca1d18cf37'/>
<id>b6c8921b7281f24f5e8353cd0542d7ca1d18cf37</id>
<content type='text'>
The pymemcache client will return a byte string, so we'll do the same to test that the deserializer works as expected.

This currently fails with Python 3.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The pymemcache client will return a byte string, so we'll do the same to test that the deserializer works as expected.

This currently fails with Python 3.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add tests for serde module</title>
<updated>2016-08-17T11:20:45+00:00</updated>
<author>
<name>Adam Chainz</name>
<email>adam@adamj.eu</email>
</author>
<published>2016-08-16T17:37:46+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/pymemcache.git/commit/?id=b75316f17617032c8dfbde2ad7b0d26ba048046a'/>
<id>b75316f17617032c8dfbde2ad7b0d26ba048046a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
