Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken with recent version of aiogram #15

Open
justanotheruser opened this issue Apr 23, 2023 · 2 comments
Open

Broken with recent version of aiogram #15

justanotheruser opened this issue Apr 23, 2023 · 2 comments

Comments

@justanotheruser
Copy link

justanotheruser commented Apr 23, 2023

Broke after aiogram commit 3ea73fbbbdfd5dd5c71e9b19e39cbd1ff99b500d

`import pytest
from aiogram_tests import MockedBot
from aiogram_tests.handler import MessageHandler
from aiogram_tests.types.dataset import BOT_COMMAND

from denis_hodge_podge_bot.handlers.start import start

@pytest.mark.asyncio
async def test_start():
requester = MockedBot(MessageHandler(start))
calls = await requester.query(BOT_COMMAND(command='start'))
answer_message = calls.send_message.fetchone().text
print(answer_message)
`

______________________________________________________________ ERROR collecting tests/test_start.py ______________________________________________________________
ImportError while importing test module 'C:\Users\Sergei\PycharmProjects\Telegram\HodgepodgeBot\tests\test_start.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
C:\Python310\lib\importlib_init_.py:126: in import_module
return _bootstrap.gcd_import(name[level:], package, level)
tests\test_start.py:2: in
from aiogram_tests import MockedBot
.......virtualenvs\HodgepodgeBot-PgelrvFb\lib\site-packages\aiogram_tests_init
.py:1: in
from .requester import MockedBot
.......virtualenvs\HodgepodgeBot-PgelrvFb\lib\site-packages\aiogram_tests\requester.py:1: in
from aiogram.utils.helper import Helper
E ModuleNotFoundError: No module named 'aiogram.utils.helper'

aiogram.utils.helper file was deleted

@alenapoliakova
Copy link

I have the same problem. Probably you, like me, installed aiogram_test version 1.0.3 from PyPI on October 26, 2022, but the problem was solved in MR #12 on February 20, 2023, after which it was moved to main and no release was released.

@OCCCAS , can you please release a new release 1.0.4 to PyPi with new changes?

@adimetrius
Copy link

Same here. Very annoying. Looks like maybe the authors have stopped working on this project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants