Skip to content

chore: Clean up python 2 legacy - #796

Open
ThosRTanner wants to merge 1 commit into
python-zk:masterfrom
ThosRTanner:issue/788/cleanup-python-2
Open

chore: Clean up python 2 legacy#796
ThosRTanner wants to merge 1 commit into
python-zk:masterfrom
ThosRTanner:issue/788/cleanup-python-2

Conversation

@ThosRTanner

@ThosRTanner ThosRTanner commented Aug 23, 2026

Copy link
Copy Markdown
Contributor

Fixes #788

Remove python2 specific code
Use python 3 style for constructors etc
Use python3.8 techniques in a few places

Why is this needed?

Code cleanup. This moves off deprecated python constructs (such as class X(object))

Proposed Changes

  • Changes class X(object): to class X:
  • changes super(Class, self) to super()
  • removes the strange (python2) handling of EINTR
  • removes from __future__ import absolute_import (an early python 3-ism)
  • other tidyups

Does this PR introduce any breaking change?

No

Coverage changes

These appear to be because it's based on 2 commits ago on master, rather than current master. This change actually increases coverage because there's now coverage of the InterruptedException path in utils.py

@codecov

codecov Bot commented Aug 23, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.46%. Comparing base (e894342) to head (075c81a).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #796      +/-   ##
==========================================
- Coverage   96.65%   95.46%   -1.19%     
==========================================
  Files          27       27              
  Lines        3554     3858     +304     
==========================================
+ Hits         3435     3683     +248     
- Misses        119      175      +56     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ThosRTanner
ThosRTanner force-pushed the issue/788/cleanup-python-2 branch 2 times, most recently from 72bdc56 to e05442d Compare August 23, 2026 19:35
Fixes python-zk#788

Remove python2 specific code
Use python 3 style for constructors etc
Use python3.8 techniques in a few places
@ThosRTanner
ThosRTanner force-pushed the issue/788/cleanup-python-2 branch from e05442d to 075c81a Compare August 23, 2026 19:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

There is still python2 ish code in the project

1 participant