Opened 2 years ago

Closed 17 months ago

#22993 closed Cleanup/optimization (fixed)

Drop skipIfCustomUser decorator

Reported by: timo Owned by: chrisjluc
Component: contrib.auth Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no


With the test discovery changes in 1.6, the tests for django.contrib apps are no longer run as part of user's project. For this reason I believe we no longer need to decorate tests in contrib.auth with @skipIfCustomUser.

Change History (10)

comment:1 Changed 2 years ago by timo

  • Triage Stage changed from Unreviewed to Someday/Maybe

django-developers thread. Consensus seems to be that we shouldn't drop it now because of projects that may still be using the old test runner.

comment:2 Changed 19 months ago by MarkusH

  • Triage Stage changed from Someday/Maybe to Accepted

Can we still deprecate it in 1.8? That way developers can use it through the LTS version and only need to upgrade to the next LTS after 1.8 and we can get rid of it in 2.0. If deprecation time for 1.8 is already over, let's do it for 1.9. Either way should give users plenty of time to update their test suite.

comment:3 Changed 19 months ago by timgraham

I'm not quite understanding your argument for why it would be advantageous to deprecate for 1.8. I think 1.9 is fine.

comment:4 Changed 17 months ago by claudep

Django's auth tests no longer use that decorator. Is the decorator still useful for reusable apps developers (then this bug can be closed)? Or do we want to remove the decorator from contrib.auth (it is currently documented)?

comment:5 Changed 17 months ago by timgraham

I don't know of any apps that ship tests that are designed to run as part of your project which would be the reason for the decorator. If we remove it from Django (after deprecation since it's documented) It's easiest enough to copy it into your project if you need it.

comment:6 Changed 17 months ago by claudep

  • Easy pickings set

comment:7 Changed 17 months ago by chrisjluc

  • Owner changed from nobody to chrisjluc
  • Status changed from new to assigned

comment:8 Changed 17 months ago by chrisjluc

  • Triage Stage changed from Accepted to Ready for checkin

comment:9 Changed 17 months ago by claudep

  • Has patch set
  • Triage Stage changed from Ready for checkin to Accepted

Hi Chris, the Ready for checkin flag is only set when someone else has reviewed your patch. Just set the Has patch flag when your pull request is ready.

comment:10 Changed 17 months ago by Tim Graham <timograham@…>

  • Resolution set to fixed
  • Status changed from assigned to closed

In e37d52b:

Fixed #22993 -- Deprecated skipIfCustomUser decorator

Note: See TracTickets for help on using tickets.
Back to Top