Я вот пользовался модулем для генерации случайных чисел, а сейчас он перестал работать. Весь код:
import random
print(random.randint(0,1))
А вот ошибка:
Traceback (most recent call last):
File "C:\Users\Dostoewsky\Desktop\projects\python_projects\random.py", line 1, in
import random
File "C:\Users\Dostoewsky\Desktop\projects\python_projects\random.py", line 2, in
print(random.randint(0,1))
AttributeError: partially initialized module 'random' has no attribute 'randint' (most likely due to a circular import)
[Finished in 108ms with exit code 1]
[cmd: ['py', '-u', 'C:\\Users\\Dostoewsky\\Desktop\\projects\\python_projects\\random.py']]
[dir: C:\Users\Dostoewsky\Desktop\projects\python_projects]
[path: C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Users\Dostoewsky\AppData\Local\Programs\Python\Python38\Scripts\;C:\Users\Dostoewsky\AppData\Local\Programs\Python\Python38\]