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

Remove code from all dist_utils.py #6296

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

Conversation

skiedude
Copy link
Contributor

@skiedude skiedude commented Jan 30, 2025

This if check was breaking the environment markers python_version in requirements.txt when installing/building the package through python setup.py ...

In st2common/requirements.txt the limitation imposed on

backports.zoneinfo[tzdata]; python_version<"3.9"

was being ignored because the if check was splitting on ; and only grabbing what was in front, thus removing this requirement that should be enforced.

This is causing a large majority if not all pack CI tests to fail because backports.zoneinfo is no longer needed in python 3.10
pganssle/zoneinfo#111
https://github.com/StackStorm-Exchange/stackstorm-vsphere/actions/runs/12839844866/job/35807686455

@pull-request-size pull-request-size bot added the size/M PR that changes 30-99 lines. Good size to review. label Jan 30, 2025
Copy link
Contributor

@nzlosh nzlosh left a comment

Choose a reason for hiding this comment

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

Great job on tracking this down. 👍

@nzlosh nzlosh requested a review from cognifloyd January 31, 2025 02:38
@skiedude
Copy link
Contributor Author

skiedude commented Feb 4, 2025

My flake8 error I assume should be fixed by #6298 since the error results from ulrlib3 on python 3.8

virtualenv-st2client/bin/st2 --version
Traceback (most recent call last):
  File "virtualenv-st2client/bin/st2", line 33, in <module>
    sys.exit(load_entry_point('st2client==3.9.dev0', 'console_scripts', 'st2')())
  File "virtualenv-st2client/bin/st2", line 25, in importlib_load_entry_point
    return next(matches).load()
  File "/opt/hostedtoolcache/Python/3.8.10/x64/lib/python3.8/importlib/metadata.py", line 77, in load
    module = import_module(match.group('module'))
  File "/opt/hostedtoolcache/Python/3.8.10/x64/lib/python3.8/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 848, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/home/runner/work/st2/st2/virtualenv-st2client/lib/python3.8/site-packages/st2client-3.9.dev0-py3.8.egg/st2client/shell.py", line 42, in <module>
    from st2client import models
  File "/home/runner/work/st2/st2/virtualenv-st2client/lib/python3.8/site-packages/st2client-3.9.dev0-py3.8.egg/st2client/models/__init__.py", line 18, in <module>
    from st2client.models.core import *  # noqa
  File "/home/runner/work/st2/st2/virtualenv-st2client/lib/python3.8/site-packages/st2client-3.9.dev0-py3.8.egg/st2client/models/core.py", line 29, in <module>
    import requests
  File "/home/runner/work/st2/st2/virtualenv-st2client/lib/python3.8/site-packages/requests-2.32.3-py3.8.egg/requests/__init__.py", line 43, in <module>
    import urllib3
  File "/home/runner/work/st2/st2/virtualenv-st2client/lib/python3.8/site-packages/urllib3-2.3.0-py3.8.egg/urllib3/__init__.py", line 14, in <module>
    from . import exceptions
  File "/home/runner/work/st2/st2/virtualenv-st2client/lib/python3.8/site-packages/urllib3-2.3.0-py3.8.egg/urllib3/exceptions.py", line 26, in <module>
    _TYPE_REDUCE_RESULT = tuple[typing.Callable[..., object], tuple[object, ...]]
TypeError: 'type' object is not subscriptable
make: *** [Makefile:537: .st2client-install-check] Error 1
Script done, file is typescript

@skiedude
Copy link
Contributor Author

skiedude commented Feb 4, 2025

The integration tests seems transient, seeing how they are all passing now with no changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/M PR that changes 30-99 lines. Good size to review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants