toxygen-project / toxygen

Toxygen is pythonic Tox client
GNU General Public License v3.0
278 stars 45 forks source link

OSError: exception: access violation reading 0xFFFFFFFF9419E570 in windows 10 64bite #82

Open EchoBlam opened 7 months ago

EchoBlam commented 7 months ago

D:\Programs\Python\Python37\python.exe -B "C:/Program Files/JetBrains/PyCharm/plugins/python-ce/helpers/pydev/pydevd.py" --multiprocess --qt-support=auto --client 127.0.0.1 --port 54854 --file C:\Users\lenovo\Desktop\toxygen-master\toxygen\main.py Connected to pydev debugger (build 233.13135.95) C:\Users\lenovo\Desktop\toxygen-master\toxygen Traceback (most recent call last): File "C:/Program Files/JetBrains/PyCharm/plugins/python-ce/helpers/pydev/pydevd.py", line 1534, in _exec pydev_imports.execfile(file, globals, locals) # execute the script File "C:\Program Files\JetBrains\PyCharm\plugins\python-ce\helpers\pydev_pydev_imps_pydev_execfile.py", line 18, in execfile exec(compile(contents+"\n", file, 'exec'), glob, loc) File "C:\Users\lenovo\Desktop\toxygen-master\toxygen\main.py", line 487, in main() File "C:\Users\lenovo\Desktop\toxygen-master\toxygen\main.py", line 483, in main toxygen.main() File "C:\Users\lenovo\Desktop\toxygen-master\toxygen\main.py", line 108, in main self.tox.self_set_name(bytes(_login.name, 'utf-8') if _login.name else b'Toxygen User') File "C:\Users\lenovo\Desktop\toxygen-master\toxygen\tox.py", line 356, in self_set_name c_size_t(len(name)), byref(tox_err_set_info)) OSError: exception: access violation reading 0xFFFFFFFF9419E570

andrewlytvyn commented 2 weeks ago

The error message you're seeing is an access violation, which usually occurs when your program tries to read or write to a part of memory that it shouldn't be accessing. This is often due to issues like passing invalid pointers or incorrect data types to low-level functions, particularly when dealing with C extensions or interfacing with libraries like tox in Python.

Here's a breakdown of possible causes and solutions:

1. Incorrect Pointer or Memory Handling:

2. Version Compatibility:

3. Platform-Specific Issues:

4. Debugging Steps:

Example Fix:

If the issue is related to the name being passed as a string when a different type is expected, you might need to correct how you're handling name:

name = _login.name.encode('utf-8') if _login.name else b'Toxygen User'
self.tox.self_set_name(name)

If this doesn't help, then the problem might be deeper in the tox library or its integration with your code, and additional debugging or even inspecting the tox source code might be necessary.

Final Step:

If none of these solutions work, consider reaching out to the maintainers of the tox library or searching for similar issues on platforms like GitHub or Stack Overflow. Providing them with the details of your environment (Python version, tox version, OS) will help diagnose the issue faster.