Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python 3.12 compatibility #1260

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Bastian-Krause
Copy link
Member

@Bastian-Krause Bastian-Krause commented Aug 24, 2023

Description
Python 3.12 is expected to be released on 2023-10-02. Now that 3.12.0-rc1 is released and the ABI settled, it's a good time to see what needs fixing. It turns out, labgrid itself works fine, but some dependencies are not ready, yet:

This draft PR works around these issues (by using pre-releases, switching from pypi to git URLs, switching to forks).

Checklist

  • PR has been tested (currently CI only)

@codecov
Copy link

codecov bot commented Aug 24, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (c4a0867) 63.1% compared to head (b4be952) 63.1%.

Additional details and impacted files
@@           Coverage Diff            @@
##           master   #1260     +/-   ##
========================================
- Coverage    63.1%   63.1%   -0.1%     
========================================
  Files         160     160             
  Lines       11914   11914             
========================================
- Hits         7520    7519      -1     
- Misses       4394    4395      +1     

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

eth-utils<2.3.0 required to circumvent the following error:

  Traceback (most recent call last):
    File "/home/runner/work/labgrid/labgrid/crossbar-venv/bin/crossbar", line 5, in <module>
      from crossbar import run
    File "/home/runner/work/labgrid/labgrid/crossbar-venv/lib/python3.12/site-packages/crossbar/__init__.py", line 19, in <module>
      import eth_abi
    File "/home/runner/work/labgrid/labgrid/crossbar-venv/lib/python3.12/site-packages/eth_abi/__init__.py", line 15, in <module>
      from eth_abi.abi import (  # NOQA
    File "/home/runner/work/labgrid/labgrid/crossbar-venv/lib/python3.12/site-packages/eth_abi/abi.py", line 1, in <module>
      from eth_abi.codec import (
    File "/home/runner/work/labgrid/labgrid/crossbar-venv/lib/python3.12/site-packages/eth_abi/codec.py", line 12, in <module>
      from eth_abi.decoding import (
    File "/home/runner/work/labgrid/labgrid/crossbar-venv/lib/python3.12/site-packages/eth_abi/decoding.py", line 8, in <module>
      from eth_utils import (
    File "/home/runner/work/labgrid/labgrid/crossbar-venv/lib/python3.12/site-packages/eth_utils/__init__.py", line 86, in <module>
      from .network import (
    File "/home/runner/work/labgrid/labgrid/crossbar-venv/lib/python3.12/site-packages/eth_utils/network.py", line 7, in <module>
      from eth_typing import ChainId
  ImportError: cannot import name 'ChainId' from 'eth_typing' (/home/runner/work/labgrid/labgrid/crossbar-venv/lib/python3.12/site-packages/eth_typing/__init__.py)

Signed-off-by: Bastian Krause <bst@pengutronix.de>
Signed-off-by: Bastian Krause <bst@pengutronix.de>
Signed-off-by: Bastian Krause <bst@pengutronix.de>
Copy link
Contributor

@sjg20 sjg20 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if upstream crossbar is doing fixes?

@Bastian-Krause
Copy link
Member Author

I wonder if upstream crossbar is doing fixes?

We will move to gRPC eventually.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants