I’m in favour of changing repr to not execute. Luke’s reasoning seems
reasonable.

On Thu, 10 Oct 2019 at 17:15, Ryan Hiebert <r...@ryanhiebert.com> wrote:

>
>
> On Thu, Oct 10, 2019 at 10:50 AM Matt <m...@satchamo.com> wrote:
>
>>
>> I think we ought to reconsider the behavior of repr on QuerySets. I'm of
>> the opinion that we should scrap it completely. It could be replaced by
>> something that generates the SQL that would be executed (although that may
>> be tricky), or some kind of representation of the query filter.
>>
>
> Just speaking for myself, I think I'm roughly in agreement with the
> general sentiment and reasoning behind your proposal. There's one place
> that I think there's common utility, and which I think is the most likely
> the cause disruption to people, the interactive prompt. The issues that
> you've mentioned are also present on the interactive prompt as well, so the
> change would be optimal there as well. Perhaps it would be possible to ease
> the pain somewhat if there were a setting to do reprs as currently, perhaps
> _only_ on the interactive prompt, to avoid the issues you've pointed out
> with tools like Sentry. I'm not sure what the default setting value should
> be, though I do think new projects should include whatever settings would
> be needed to make this the default behavior for new projects, even if the
> setting default was to maintain backward compatibility, as has been done
> for other settings.
>
> tl;dr: I like the motivation, but I'm not sure how the backward
> compatibility aspects will play out for the community.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/CABpHFHS1%3DirRaQVWgiUnmTX%2By%3DB7Vy%2BpGLha-aoYmqTGUSj20g%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-developers/CABpHFHS1%3DirRaQVWgiUnmTX%2By%3DB7Vy%2BpGLha-aoYmqTGUSj20g%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>
-- 
Adam

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAMyDDM0XNtKYEVy3kMGz0mFD5JHcOdLzEb5fDj22jpsKAr4vjQ%40mail.gmail.com.
  • ... Matt
    • ... Ryan Hiebert
      • ... Adam Johnson
    • ... Matt
      • ... Ryan Hiebert
    • ... Matt
    • ... Mariusz Felisiak
      • ... Carlton Gibson
        • ... 'Alexandr Aktsipetrov' via Django developers (Contributions to Django itself)
        • ... James Bennett
          • ... charettes
            • ... Harro
              • ... Mariusz Felisiak

Reply via email to