#27546: Replace hardcoded class names in __repr__-methods
-------------------------------------+-------------------------------------
     Reporter:  Mads Jensen          |                    Owner:  Adiyat
         Type:                       |  Mubarak
  Cleanup/optimization               |                   Status:  assigned
    Component:  Core (Other)         |                  Version:  1.10
     Severity:  Normal               |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  1                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by Adiyat Mubarak):

 Replying to [ticket:27546 Mads Jensen]:
 > I noticed there are a few places where {{{__repr__}}} does not use
 {{{self.__class__.__name__}}}. I think this is a small clean-up that would
 make sense to do, but perhaps there was a good reason not to do that
 (probably they're never subclassed?). The following output is from grep:
 >
 > {{{
 > django/db/models/query.py:        return "<RawQuerySet: %s>" %
 self.query
 > django/db/models/sql/query.py:        return "<RawQuery: %s>" % self
 > django/db/migrations/state.py:        return "<ModelState: '%s.%s'>" %
 (self.app_label, self.name)
 > django/utils/baseconv.py:        return "<BaseConverter: base%s (%s)>" %
 (len(self.digits), self.digits)
 > django/core/management/commands/makemessages.py:        return
 "<TranslatableFile: %s>" % os.sep.join([self.dirpath, self.file])
 > django/core/serializers/base.py:        return "<DeserializedObject:
 %s(pk=%s)>" % (
 > }}}

 Hi, I just learn to contribute on django project by taking this easy task
 on this [https://github.com/django/django/pull/7629 PR]
 Do I need to update this ticket to `resolve as fixed`? or this ticket will
 closed automatically?

 Thank in advance

--
Ticket URL: <https://code.djangoproject.com/ticket/27546#comment:3>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/068.08e05749da064d3c67a890abe9f69a63%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to