1

Using python wrapper for AWS S3 upload, i want to save a key object in the django models. Using PickledObjectField to store that key object in my model, On saving it says:

Key is not JSON serializable

i have tried by passing key object as json.loads(key_obj) , but got same error.

navyad
  • 3,533
  • 6
  • 43
  • 78

1 Answers1

1

There are many ways to achieve this. But the basic idea is that you need to create your own json serializer for boto.s3.key.Key. I will leave it for you to choose the methods and the implementation details. Let me know if you still stuck with the implementation.

Community
  • 1
  • 1
Yeo
  • 10,608
  • 6
  • 62
  • 89