• 
      

    Add version-specific deprecation warnings and flag all for 2.0.

    Review Request #10260 — Created Oct. 22, 2018 and submitted

    Information

    Djblets
    release-1.0.x
    e08a6aa...

    Reviewers

    This introduces a new djblets.deprecation class, which currently
    defines DeprecationWarning subclasses for Djblets, and a utility
    function for defining warn-on-access deprecated arguments for functions,
    signal handlers, etc. The warnings are the meat of this change, and
    include a base class, BaseRemovedInDjbletsVersionWarning, a
    subclass specific to Djblets 2.0, RemovedInDjblets20Warning, and
    an alias for the version-specific warning,
    RemovedInNextDjbletsVersionWarning.

    These allow us to specify when exactly a particular feature will be
    removed, so it's clear to consumers and so we can easily locate them
    when getting ready to remove features. It also helps keep us consistent
    with when we actually remove deprecated features.

    All current DeprecationWarnings have been updated to use the 2.0
    warning. Some of the messages referred to Djblets 0.9 or 1.0, and we
    clearly never got rid of that code for those versions, so those have
    been updated to reference 2.0, where they'll actually be removed.

    All unit tests pass.

    Description From Last Updated

    F821 undefined name 'warnings'

    reviewbotreviewbot

    F821 undefined name 'warnings'

    reviewbotreviewbot
    Checks run (1 failed, 1 succeeded)
    flake8 failed.
    JSHint passed.

    flake8

    chipx86
    chipx86
    david
    1. Ship It!
    2. 
        
    chipx86
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-1.0.x (baf9641)