title: Django rest framework and python3.5 OrderedDict mutated during iteration
body: <p>I use Django rest framework and python3.5. Earlier I had another version of python and everything was going right. When I want to get some information from server with URL for example like: </p>
  
  <blockquote>
    <p>"<a href="http://127.0.0.1:8000/api/companies" rel="nofollow">http://127.0.0.1:8000/api/companies</a>"</p>
  </blockquote>
  
  <p>I'm getting error: </p>
  
  <blockquote>
    <p>"OrderedDict mutated during iteration"</p>
  </blockquote>
  
  <p>.</p>
  
  <p>In views.py I have:</p>
  
  <pre><code>from django.shortcuts import render
  from companies.models import Companies
  from companies.serializers import CompaniesSerializer
  from rest_framework import generics
  from rest_framework.response import Response
  from rest_framework.renderers import JSONRenderer
  from rest_framework import status
  
  
  class CompaniesList(generics.ListCreateAPIView):
      queryset = Companies.objects.all()
      serializer_class = CompaniesSerializer
  
  
  class CompaniesDetail(generics.RetrieveUpdateDestroyAPIView):
      queryset = Companies.objects.all()
      serializer_class = CompaniesSerializer
  </code></pre>
  
  <p>What should I do to make it working? Where is something mutating the dict?</p>