Switch from pkg_resources to modern packaging support.

Review Request #13146 — Created July 13, 2023 and submitted

Information

Review Board
release-6.x

Reviewers

pkg_resources is on its way out, with importlib.resources and
importlib.metadata taking over much of the functionality.

This change updates our codebase to use these modern modules (by way of
backport modules depended on by Djblets) instead of pkg_resources.
The updates are largely straightforward, with the biggest change being a
migration for reviewboard.wsgi to remove the import and some old
multi-versioned install setup code originally contributed by Fedora.

Unit tests pass.

Verified that hosting services and SCMTools loaded by entrypoint were
available.

Tested upgrading older reviewboard.wsgi files.

Tested new sites with the updated reviewboard.wsgi file.

Tested the help output of rb-site to verify listed file paths.

Tested rbext create.

Summary ID
Switch from pkg_resources to modern packaging support.
`pkg_resources` is on its way out, with `importlib.resources` and `importlib.metadata` taking over much of the functionality. This change updates our codebase to use these modern modules (by way of backport modules depended on by Djblets) instead of `pkg_resources`. The updates are largely straightforward, with the biggest change being a migration for `reviewboard.wsgi` to remove the import and some old multi-versioned install setup code originally contributed by Fedora.
76841bc4a3876a2938e9f8610be3be898e6d4d25
Description From Last Updated

module level import not at top of file Column: 1 Error code: E402

reviewbotreviewbot

'importlib_metadata' imported but unused Column: 1 Error code: F401

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

flake8

david
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-6.x (db8a124)
Loading...