mortafix / autoconv-telegram-python Goto Github PK
View Code? Open in Web Editor NEWPython package to handle automatic conversation in a Telegram bot.
License: MIT License
Python package to handle automatic conversation in a Telegram bot.
License: MIT License
As the title says, add_text() allows every Filter to go through. For example, if you send a media in a State with the add_text(), it goes on the default state right after.
FIRST ERROR:
stopping the Bot while in a state with back button enabled will cause an exception when restarted the bot by pressing the back button.
Exception:
'NoneType' object has no attribute 'name'
Traceback:
File "C:\Users\Andrea\Dev\Python\telegram_bots\channel_manager\venv\lib\site-packages\autoconv\autoconv_handler.py", line 359, in manage_conversation
state = self._change_state(typed_data)
File "C:\Users\Andrea\Dev\Python\telegram_bots\channel_manager\venv\lib\site-packages\autoconv\autoconv_handler.py", line 92, in _change_state
{"prev_state": self.prev_state.name, "state": new_state.name}
SECOND ERROR:
True raises AttributeError.
Traceback (most recent call last):
File "bot.py", line 7, in <module>
from states import STATE, autoconv, errore
File "C:\Users\Andrea\Dev\Python\telegram_bots\channel_manager\states.py", line 76, in <module>
bit.add_routes(wip, default=menu, back=True)
File "pydantic\decorator.py", line 52, in pydantic.decorator.validate_arguments.validate.wrapper_function
"""
File "pydantic\decorator.py", line 145, in pydantic.decorator.ValidatedFunction.call
names = set([name] + [arg.strip(' *') for arg in
File "pydantic\decorator.py", line 142, in pydantic.decorator.ValidatedFunction.init_model_instance
if mo is None:
File "pydantic\main.py", line 400, in pydantic.main.BaseModel.__init__
pydantic.error_wrappers.ValidationError: 1 validation error for AddRoutes
back
instance of State expected (type=type_error.arbitrary_type; expected_arbitrary_type=State)
Please add some images/screenshots of how it's look after an installing.
As title, an option to set the back button to dynamically change state into prev state.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.