diff --git a/django/core/serializers/json.py b/django/core/serializers/json.py
index 72053e1..0246ad6 100644
a
|
b
|
class Serializer(PythonSerializer):
|
36 | 36 | # Prevent trailing spaces |
37 | 37 | self.json_kwargs['separators'] = (',', ': ') |
38 | 38 | self.stream.write("[") |
| 39 | self.progress = 1.0 |
39 | 40 | |
40 | 41 | def end_serialization(self): |
41 | 42 | if self.options.get("indent"): |
… |
… |
class Serializer(PythonSerializer):
|
46 | 47 | |
47 | 48 | def end_object(self, obj): |
48 | 49 | # self._current has the field data |
| 50 | import sys |
| 51 | from django.core.management.base import OutputWrapper |
49 | 52 | indent = self.options.get("indent") |
50 | 53 | if not self.first: |
51 | 54 | self.stream.write(",") |
… |
… |
class Serializer(PythonSerializer):
|
56 | 59 | json.dump(self.get_dump_object(obj), self.stream, |
57 | 60 | cls=DjangoJSONEncoder, **self.json_kwargs) |
58 | 61 | self._current = None |
| 62 | if not isinstance(self.stream, OutputWrapper): |
| 63 | sys.stdout.write("\rProgress: "+str(self.progress)+"%") |
| 64 | self.progress+=5.0 |
59 | 65 | |
60 | 66 | def getvalue(self): |
61 | 67 | # Grand-parent super |