@heshhe

Pythonanywhere and vkbottle, почему выходит ошибка при импорте модуля в код?

Сделал бота с помощью vkbottle, залил на pythonanywhere и первой же строчкой он мне выдал ошибку..
Первая строка:
from vkbottle import Bot, Message, keyboard_gen, types

Ошибка:

[VKBottle] Making API request groups.getById to get group_id [TIME 04-04 10:28:34]Traceback (most recent call last):
Traceback (most recent call last):
  File "/home/heshhe/zanovo.py", line 3, in <module>
    from vkbottle import Bot, Message, keyboard_gen, types
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/__init__.py", line 1, in <module>
    from .framework import Bot, Branch, ExitBranch, User, rule, branch
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/__init__.py", line 1, in <module>
    from .bot import Bot
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/bot.py", line 10, in <module>
    from .branch import BranchManager
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/__init__.py", line 1, in <module>
    from .branch import BranchManager
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/branch.py", line 4, in <module>
    from .cls import FunctionBranch, AbstractBranch
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/cls.py", line 4, in <module>
    from ...types import Message
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/__init__.py", line 1, in <module>
    from . import additional, attachments
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/additional/__init__.py", line 6, in <module>
    from .place import Place, GeoPlace
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/additional/place.py", line 6, in <module>
    class Place(BaseModel):
  File "pydantic/main.py", line 199, in pydantic.main.ModelMetaclass.__new__
Traceback (most recent call last):
  File "/home/heshhe/zanovo.py", line 3, in <module>
    from vkbottle import Bot, Message, keyboard_gen, types
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/__init__.py", line 1, in <module>
    from .framework import Bot, Branch, ExitBranch, User, rule, branch
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/__init__.py", line 1, in <module>
    from .bot import Bot
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/bot.py", line 10, in <module>
    from .branch import BranchManager
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/__init__.py", line 1, in <module>
    from .branch import BranchManager
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/branch.py", line 4, in <module>
    from .cls import FunctionBranch, AbstractBranch
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/cls.py", line 4, in <module>
    from ...types import Message
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/__init__.py", line 1, in <module>
    from . import additional, attachments
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/additional/__init__.py", line 6, in <module>
    from .place import Place, GeoPlace
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/additional/place.py", line 6, in <module>
    class Place(BaseModel):
  File "pydantic/main.py", line 199, in pydantic.main.ModelMetaclass.__new__
Traceback (most recent call last):
  File "/home/heshhe/zanovo.py", line 3, in <module>
    from vkbottle import Bot, Message, keyboard_gen, types
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/__init__.py", line 1, in <module>
    from .framework import Bot, Branch, ExitBranch, User, rule, branch
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/__init__.py", line 1, in <module>
    from .bot import Bot
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/bot.py", line 10, in <module>
    from .branch import BranchManager
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/__init__.py", line 1, in <module>
    from .branch import BranchManager
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/branch.py", line 4, in <module>
    from .cls import FunctionBranch, AbstractBranch
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/framework/branch/cls.py", line 4, in <module>
    from ...types import Message
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/__init__.py", line 1, in <module>
    from . import additional, attachments
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/additional/__init__.py", line 6, in <module>
    from .place import Place, GeoPlace
  File "/home/heshhe/.local/lib/python3.7/site-packages/vkbottle/types/additional/place.py", line 6, in <module>
    class Place(BaseModel):
  File "pydantic/main.py", line 199, in pydantic.main.ModelMetaclass.__new__
  File "pydantic/fields.py", line 277, in pydantic.fields.ModelField.infer
  File "pydantic/fields.py", line 249, in pydantic.fields.ModelField.__init__
  File "pydantic/fields.py", line 329, in pydantic.fields.ModelField.prepare
  File "pydantic/fields.py", line 391, in pydantic.fields.ModelField._type_analysis
  File "/usr/lib/python3.7/typing.py", line 716, in __subclasscheck__
    return issubclass(cls, self.__origin__)
TypeError: issubclass() arg 1 must be a class


Устанавливал модуль через баш консоль командой pip3.7 install --user vkbottle
Пробовал на 3.8 python, пробовал устанавливать vkbottle 2.5, не помогло, не понимаю в чем дело
  • Вопрос задан
  • 70 просмотров
Решения вопроса 1
@kicherov_maxim
Используйте виртуальное окружение для управлением зависимостями. Не устанавливайте пакеты глобально.
Ответ написан
Пригласить эксперта
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Войти через центр авторизации
Похожие вопросы
26 мая 2020, в 02:01
4500 руб./за проект
26 мая 2020, в 00:42
10000 руб./за проект
25 мая 2020, в 22:16
3000 руб./за проект