-
Notifications
You must be signed in to change notification settings - Fork 104
Description
The code I ran:
import gymnasium as gym
from gym_trading_env.environments import TradingEnv
env = gym.make(
"TradingEnv",
df=df,
positions=[-1, 0, 1],
initial_position=1
)
The problem is that the process never finishes (hangs indefinitely).
I have waited for more than one hour, but there’s no output, no error message, and no crash — it just stays stuck on the gym.make(...) line.
Steps to reproduce
Install dependencies:
!pip install \
"gymnasium==0.28.1" \
"gym-trading-env==0.3.2" \
"ccxt==3.0.59" \
"nest_asyncio"
Run the script above.
The process hangs when creating or importing TradingEnv.
Expected behavior
The environment should initialize successfully and return an environment instance.
Actual behavior
The process just hangs and never completes. No error messages appear.
Additional context
I already tried downgrading gymnasium (0.28.1 and 0.27.x), but the issue persists.
Python version: (e.g., 3.12)
Environment: (Google Colab )
It might be stuck in an infinite loop or a blocking call during environment initialization.
