Repository navigation
Conversation
Current coverage is
|
|
Is this backward compatible? |
There was a problem hiding this comment.
Should we then also remove PickleType, if it's no longer used?
|
I need to check this, but I believe it is backward compatible while the result encoding type is set to 'pickle'. If the user has result encoding set to 'json' for instance, then it will change the behaviour (I suddenly found readable data that I can access easily) |
|
I was trying to merge this into master, and it does not pass tests, it seems to be missing some critical parts, like deserialization of the task/group payloads :( |
Conflicts: celery/backends/database/__init__.py celery/backends/database/models.py
Encode and decode result when using groups
|
Ugh. I need to dig up a Vagrant/Docker celery + rabbitmq + db environment |
|
@m4ddav3: |
|
No database in that environment though, but shouldn't be too difficult to add |
|
@ask ,
In order to keep in-line with the current methodology, but still be able to implement a JSON serializer, I suggest adding jsonpickle. This should enable enough compatibility to the current scheme of encoding/decoding exceptions and/or other serializable Python objects. What do you think? |
|
jsonpickle would be nice, but sadly it has the same security concern as pickle, which is the ability to deserialize arbitrary objects by attribute path. The tests must be rewritten to use json-safe data only, not sure how much work that is :( |
|
I created #5907, which is a rebased and slightly updated version of this PR. |
Use the BLOB as an sa.BLOB
Serialise the result an add to the db as bytes