Skip to content

Retriving Data from Models raising Invalid token, No exception message supplied Error #9

@AnandMoorthy

Description

@AnandMoorthy

Hello,

Encrypting the models are good, but after the encryption, if I want to get the data by the id of the row i get the exception error like mentioned above.
My Modal

from fernet_fields import EncryptedCharField

class MyModal(models.Model): 
    name = EncryptedCharField(max_length=50, default='')

My code

from app.models import MyModal

def get_details(request):
    data_id = request.GET.get('id')
    data = MyModal.objects.filter(id=data_id)
    print data
    return HttpResponse('Success')

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions