Fix compatibility with Python 2.7.

Review Request #12127 — Created March 8, 2022 and submitted

Information

RBTools
master

Reviewers

Because enterprises tend to move very slowly, we're keeping Python 2.7
compatibility for RBTools 3.0. Two issues had snuck in that were
breaking this:

  1. We had renamed uses of assertRaisesRegexp to use the new
    assertRaisesRegex name. Unfortunately, this new name is only Python
    3.1+. I've changed it back, and made two uses of it instead call the
    more appropriate assertRaisesMessage helper, so now there's only
    one place that hits it.
  2. The tqdm library depends on importlib_resources. Unfortunately,
    while tqdm is maintaining Python 2.7 compatibility, the newer
    versions of its dependency are not. I've added a pin for the last
    compatible version.

Ran setup.py develop under Python 2.7, and then ran all unit tests.

Summary ID
Fix compatibility with Python 2.7.
Because enterprises tend to move very slowly, we're keeping Python 2.7 compatibility for RBTools 3.0. Two issues had snuck in that were breaking this: 1. We had renamed uses of `assertRaisesRegexp` to use the new `assertRaisesRegex` name. Unfortunately, this new name is only Python 3.1+. I've changed it back, and made two uses of it instead call the more appropriate `assertRaisesMessage` helper, so now there's only one place that hits it. 2. The `tqdm` library depends on `importlib_resources`. Unfortunately, while tqdm is maintaining Python 2.7 compatibility, the newer versions of its dependency are not. I've added a pin for the last compatible version. Testing Done: Ran setup.py develop under Python 2.7, and then ran all unit tests.
4f438a024a366b5b49a0c0746a15fcb0a3cc4c61
Description From Last Updated

E128 continuation line under-indented for visual indent

reviewbotreviewbot

E128 continuation line under-indented for visual indent

reviewbotreviewbot

Can you separate these with a blank line?

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

flake8

david
chipx86
  1. 
      
  2. setup.py (Diff revision 2)
     
     
     

    Can you separate these with a blank line?

  3. 
      
david
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to master (fb453a9)
Loading...