Skip to content

[ci] add python >= 3.10 for gymnasium to make windows CI happy - #59572

Merged
aslonnie merged 1 commit into
masterfrom
lonnie-251218-gympy
Dec 19, 2025
Merged

aslonnie merged 1 commit into
masterfrom
lonnie-251218-gympy

Conversation

@aslonnie

Copy link
Copy Markdown
Contributor

we can remove the python version constraint after windows CI is migrated to python 3.9

Comment thread python/requirements.txt
@@ -1,4 +1,4 @@
# These are mirrored in setup.py as install_requires,
# These are mirrored in setup.py as install_requires,a

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Bug: Accidental character added to comment line

A stray character a was accidentally appended to the end of the comment on line 1, changing install_requires, to install_requires,a. This appears to be an unintentional typo that was committed alongside the intended gymnasium version constraint change.

Fix in Cursor Fix in Web

Comment thread python/requirements.txt
@@ -1,4 +1,4 @@
# These are mirrored in setup.py as install_requires,
# These are mirrored in setup.py as install_requires,a

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Bug: Accidental character added to comment line

A stray character a was accidentally appended to the end of the comment on line 1, changing install_requires, to install_requires,a. This appears to be an unintentional typo that was committed alongside the intended gymnasium version constraint change.

Fix in Cursor Fix in Web

Comment thread python/requirements.txt
@@ -39,7 +39,7 @@ opentelemetry-api
opentelemetry-exporter-prometheus
opentelemetry-proto
fastapi
gymnasium==1.2.2
gymnasium==1.2.2; python_version >= '3.10'

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Bug: Gymnasium constraint not synchronized to setup.py

The Python version constraint python_version >= '3.10' was added for gymnasium in requirements.txt, but setup.py line 325 still has gymnasium==1.2.2 without this constraint. The comment at the top of requirements.txt explicitly states to synchronize changes to setup.py. Users installing ray[rllib] via pip will still encounter the original Windows CI issue since the constraint wasn't applied consistently.

Fix in Cursor Fix in Web

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request adds a Python version constraint to the gymnasium dependency in python/requirements.txt, restricting it to Python 3.10 and newer. This is intended to resolve issues on the Windows CI. My review includes a minor fix for a typo in a comment and a more important point about maintaining consistency with setup.py, where the same dependency needs to be updated.

Comment thread python/requirements.txt
@@ -39,7 +39,7 @@ opentelemetry-api
opentelemetry-exporter-prometheus
opentelemetry-proto
fastapi
gymnasium==1.2.2
gymnasium==1.2.2; python_version >= '3.10'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

high

The comment at the top of this file (lines 1-5) mentions that changes should be mirrored in setup.py. The gymnasium dependency is also present in python/setup.py for the rllib extra (line 325), but it lacks this Python version constraint. To maintain consistency between developer and user installations, please add the version constraint to setup.py as well.

# python/setup.py:325
        "gymnasium==1.2.2; python_version >= '3.10'",

Comment thread python/requirements.txt
@@ -1,4 +1,4 @@
# These are mirrored in setup.py as install_requires,
# These are mirrored in setup.py as install_requires,a

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

There appears to be a small typo in this comment. It seems 'install_requires,a' should be 'install_requires,'.

# These are mirrored in setup.py as install_requires,

@aslonnie
aslonnie requested a review from a team December 19, 2025 07:34
@aslonnie aslonnie added the go add ONLY when ready to merge, run all tests label Dec 19, 2025
@ray-gardener ray-gardener Bot added the devprod label Dec 19, 2025
we can remove the python version constraint after windows
CI is migrated to python 3.9

Signed-off-by: Lonnie Liu <[email protected]>
Signed-off-by: Lonnie Liu <[email protected]>
@aslonnie
aslonnie force-pushed the lonnie-251218-gympy branch from f65a90d to 20224d8 Compare December 19, 2025 13:16
@aslonnie
aslonnie merged commit b7c6e97 into master Dec 19, 2025
@aslonnie
aslonnie deleted the lonnie-251218-gympy branch December 19, 2025 13:45
ArturNiederfahrenhorst pushed a commit that referenced this pull request Dec 29, 2025
## Description
bump gymnasium to 1.2.2 in byod-rllib
follow up on:
* #59530

related:
* #59572

Signed-off-by: Kamil Kaczmarek <[email protected]>
AYou0207 pushed a commit to AYou0207/ray that referenced this pull request Jan 13, 2026
…roject#59572)

we can remove the python version constraint after windows CI is migrated
to python 3.9

Signed-off-by: Lonnie Liu <[email protected]>
Signed-off-by: Lonnie Liu <[email protected]>
Signed-off-by: jasonwrwang <[email protected]>
AYou0207 pushed a commit to AYou0207/ray that referenced this pull request Jan 13, 2026
## Description
bump gymnasium to 1.2.2 in byod-rllib
follow up on:
* ray-project#59530

related:
* ray-project#59572

Signed-off-by: Kamil Kaczmarek <[email protected]>
Signed-off-by: jasonwrwang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

devprod go add ONLY when ready to merge, run all tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants