[Answered ]-Django-concurrency is doing nothing

2👍

I have never used Django concurrency and I would run a mile if I run across apps that offer to abstract concurrency, transaction management etc. Based on general concepts of concurrency. This behaviour seems right. There’s no error here.

django-concurrency is an optimistic lock [1] implementation for
Django.

Supported Django versions: 1.8.x, 1.9.x, 1.10.x., 1.11.x

It prevents users from doing concurrent editing in Django both from UI
and from a django command.

What this actually means is that two users cannot modify the same instance at the same time. In adhoc two browser testing of the sort that’s just tried out, such a situation can never be produced! What usually happens is that one or the other transaction usually runs to completion because when testing on small databases on localhost, there is no latency and everything happens instantly.

The proper way to test this is to open up to separate change shells, open up the same instance and edit as outlined in the django concurrency guide. Or test with a multi threaded client.

👤e4c5

Leave a comment