reloadware / reloadium

Hot Reloading and Profiling for Python
https://reloadium.io
Apache License 2.0
2.74k stars 56 forks source link

Python 3.7.4 venv raise: ModuleNotFoundError: No module named 'reloadium.corium' #164

Closed qy527145 closed 9 months ago

qy527145 commented 9 months ago

Describe the bug*

低版本的python环境下,使用reloadium run main.py提示:ModuleNotFoundError: No module named 'reloadium.corium'

To Reproduce

Steps to reproduce the behavior:

  1. 创建虚拟环境:py -3.7 -m venv bug
  2. 激活虚拟环境:bug\Scripts\activate
  3. 安装reloadium:pip install reloadium
  4. 创建测试脚本:echo print('hello') > main.py
  5. 设置环境变量:set RW_DEBUG=True
  6. 使用reloadium:reloadium run main.py

Expected behavior

在3.7.4版本Python环境下存在这个问题,但是在3.10、3.11版本的Python环境下正常

Screenshots

reloadium run main.py
It seems like your platform or Python version are not supported yet.
Windows, Linux, macOS and Python 64 bit >= 3.7 (>= 3.9 for M1) <= 3.11 are currently supported.
Please submit a github issue if you believe Reloadium should be working on your system at
https://github.com/reloadware/reloadium
To see the exception run Reloadium with environmental variable RW_DEBUG=True
Traceback (most recent call last):
  File "D:\Python\Python3_7_4\lib\runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "D:\Python\Python3_7_4\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\xuqiao\Desktop\www\Scripts\reloadium.exe\__main__.py", line 5, in <module>
  File "c:\users\xuqiao\desktop\www\lib\site-packages\reloadium\__init__.py", line 4, in <module>
    pre_import_check()
  File "c:\users\xuqiao\desktop\www\lib\site-packages\reloadium\__utils__.py", line 24, in pre_import_check
    import reloadium.corium
ModuleNotFoundError: No module named 'reloadium.corium'

Desktop or remote (please complete the following information):**

Additional context

Add any other context about the problem here.

dkrystki commented 9 months ago

Hi @qy527145 python 3.7 is not supported anymore. I'll update the message in the next release

qy527145 commented 9 months ago

Hi @qy527145 python 3.7 is not supported anymore. I'll update the message in the next release

我在Python 3.7.4的虚拟环境中使用pip安装了低版本的reloadium==1.1.0 运行reloadium run 提示:

This Reloadium version is obsolete.
Please update by running "pip install reloadium --upgrade"

这似乎是reloadium内置的过时检测,有没有办法绕过这个检测呢? 由于某些依赖包兼容性问题,升级python比较困难,有什么好的建议吗?