python-can icon indicating copy to clipboard operation
python-can copied to clipboard

CAN Devices Not Detected When Executable Is Run

Open abcde4631 opened this issue 1 year ago • 1 comments

Describe the bug

Hi,

I'm using your application to forward messages between CAN buses, and I've noticed an issue when running the executable file. When I call the detect_available_configs function, it does not detect any CAN devices. However, when I run the Python script directly, the CAN devices are detected without any problems. image 微信图片_20240818184210

To Reproduce

Expected behavior

Additional context

OS and version: Windows 10 Python version:Python 3.8.5 python-can version:4.2.2 python-can interface/s (if applicable):detect_available_configs Executable Creation Tool:auto-py-to-exe,cmd is:pyinstaller --noconfirm --onefile --windowed --hidden-import "Pyqt5-sip" --hidden-import "can" --hidden-import "python-can" "C:\Users\Administrator\Desktop\TsPy" "C:\Users\Administrator\Desktop\TsPy\zhuanfagui.py"

Traceback and logs
def func():
    return "hello, world!"

abcde4631 avatar Aug 18 '24 10:08 abcde4631

I'm having the same problem, please help me fix it。

JRYman92 avatar Nov 08 '24 07:11 JRYman92