Custom Search

SUBSCRIBE

SUBSCRIBE : 300 + Free Video Tutorials Programming (Python, golang, Julia), DevOps

Wednesday, November 30, 2016

python django AttributeError: 'module' object has no attribute 'commit_on_success'

Error:
from django.db import connection, transaction
@transaction.commit_on_success
AttributeError: 'module' object has no attribute 'commit_on_success'

Fix:
@transaction.commit_on_success has been deprecated in Django 1.6, use
@transaction.atomic() decorator instead of @transaction.commit_on_success

No comments:

Post a Comment