• 
      

    Remove the app_name for integration URLs.

    Review Request #10472 — Created March 27, 2019 and submitted

    Information

    Djblets
    release-2.0.x

    Reviewers

    Django 1.6 happily allows an application namespaec (app_name) to be
    specified for any URLs, but newer 1.x versions only allow this if an
    instance namespace (namespace) is being provided. Django 2.x doesn't
    allow the parameter at all, instead requiring a whole different process
    for specifying the app namespace.

    This change removes the application namespace entirely for integration
    URLs. We don't use it to resolve URLs ourselves, and callers can always
    provide their own namespace, so there's not much point in keeping this
    around.

    Djblets and Review Board unit tests pass on Django 1.6 and 1.11.

    Summary ID
    Remove the app_name for integration URLs.
    Django 1.6 happily allows an application namespaec (`app_name`) to be specified for any URLs, but newer 1.x versions only allow this if an instance namespace (`namespace`) is being provided. Django 2.x doesn't allow the parameter at all, instead requiring a whole different process for specifying the app namespace. This change removes the application namespace entirely for integration URLs. We don't use it to resolve URLs ourselves, and callers can always provide their own namespace, so there's not much point in keeping this around.
    4ca45556cef596c28ee3dc9da9bfa2b0d4958afd
    Description From Last Updated

    Hmm, actually, this comment is confusing (seems backwards to the code).

    daviddavid
    david
    1. Ship It!
    2. 
        
    david
    1. 
        
    2. djblets/integrations/urls.py (Diff revision 1)
       
       
      Show all issues

      Hmm, actually, this comment is confusing (seems backwards to the code).

      1. It's the right way. If we're going to set an app_name, a namespace must be provided. Namespaces, however, do not require an app_name.

      2. I'm just saying the way it's written makes either the comment or the code seem wrong. How about "Django requires that we specify either both a namespace and app_name or neither."

      3. Turns out the app_name parameter to include is deprecated, and they have a new method for dealing with app names that Django 1.6 doesn't support. Sooo I'm just going to remove this entirely :) We don't really make use of it anywhere.

    3. 
        
    chipx86
    chipx86
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-2.0.x (7241bdc)