• 
      

    Add type hints, missing docs, enums, and cleanup to djblets.features.

    Review Request #12991 — Created April 27, 2023 and submitted

    Information

    Djblets
    release-3.x

    Reviewers

    This adds missing type hints to djblets.features, and in the process
    updates some of the code to add missing docstrings and to fix types in
    some docstrings.

    FeatureLevel is now an enum, which should be backwards-compatible
    with the original int in how this is used. That gives better type
    checking than using an int.

    FeatureRegistry has been updated to be a typed registry.

    Unit tests pass.

    Tested with some code defining a new feature.

    Summary ID
    Add type hints, missing docs, enums, and cleanup to djblets.features.
    This adds missing type hints to `djblets.features`, and in the process updates some of the code to add missing docstrings and to fix types in some docstrings. `FeatureLevel` is now an enum, which should be backwards-compatible with the original `int` in how this is used. That gives better type checking than using an `int`. `FeatureRegistry` has been updated to be a typed registry.
    2fda6a10798ac38c88dc883bd9ad471830158729
    david
    1. Ship It!
    2. 
        
    chipx86
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-3.x (a8806cd)