Closed VivatPrograms closed 1 year ago
I also have python 3.10 everywhere, but there are no such problems. And judging by the traceback, this is a problem with pydantic. I don't know how to reproduce it
is there a workaround this problem, the problem only exists in pythonanywhere but not on my local machine
I don't know, write them a question
Traceback (most recent call last): File "/home/VivatGrunwald/bot.py", line 1, in
from instagrapi import Client
File "/home/VivatGrunwald/.local/lib/python3.10/site-packages/instagrapi/init.py", line 7, in
from instagrapi.mixins.account import AccountMixin
File "/home/VivatGrunwald/.local/lib/python3.10/site-packages/instagrapi/mixins/account.py", line 8, in
from instagrapi.extractors import extract_account, extract_user_short
File "/home/VivatGrunwald/.local/lib/python3.10/site-packages/instagrapi/extractors.py", line 6, in
from .types import (
File "/home/VivatGrunwald/.local/lib/python3.10/site-packages/instagrapi/types.py", line 13, in
class Resource(BaseModel):
File "pydantic/main.py", line 197, in pydantic.main.ModelMetaclass.new
File "pydantic/fields.py", line 506, in pydantic.fields.ModelField.infer
File "pydantic/fields.py", line 436, in pydantic.fields.ModelField.init
File "pydantic/fields.py", line 552, in pydantic.fields.ModelField.prepare
File "pydantic/fields.py", line 668, in pydantic.fields.ModelField._type_analysis
File "/usr/local/lib/python3.10/typing.py", line 1157, in subclasscheck
return issubclass(cls, self.origin)
TypeError: issubclass() arg 1 must be a class
Why does this error happen I can't find an answer to it for hours, adw0rd, maybe you know more about this?