guilherme-vasconcelos / aqua Goto Github PK
View Code? Open in Web Editor NEWA Telegram bot for personal utilities
License: GNU Affero General Public License v3.0
A Telegram bot for personal utilities
License: GNU Affero General Public License v3.0
Describe your idea
https://github.com/psf/black
https://github.com/PyCQA/isort
Also remember to add recommended vscode extensions
Also remember to ensure black's config is compatible with flake8 (or remove flake8 completely), then adapt github action workflow accordingly
https://code.visualstudio.com/docs/python/editing#_sort-imports
Describe your idea
Gives you the definition of a certain text.
Extra information
Maybe get the information from Wikipedia: https://foundation.wikimedia.org/wiki/Terms_of_Use/en
https://www.mediawiki.org/wiki/API:Search
https://www.mediawiki.org/wiki/API:Main_page
https://www.mediawiki.org/wiki/Extension%3aTextExtracts#API
Describe your idea
The current pre-commit hook (located at hooks/pre-commit
) is not completely reliable because it doesn't check for tricks such as:
For instance, these two snippets would be considered OK to the current pre-commit hook:
# @authorize
def start(...):
...
'@authorize'
def start(...):
...
The task is to create a pre-commit hook that actually checks:
/help
command: aqua/extensions/commands/help.py;Extra information
.github/workflows/pre-commit.yml
).def start(...)
needs an authorize if it is located inside the start.py
file._
such as /_invalid
, which is to be merged in command-abreviations
branch) should not be documented in /help
or README, though they must still have an authorize.Describe your idea
E.g. use the command /l instead of /lorem.
If there are more commands that begin with l
, the user should type at least the minimum required for it to be identified as a shortened version of lorem
.
Extra information
Maybe a way to implement would be to create at startup time all the unambiguous abbreviations of all the methods, for instance: l
, lo
, lor
, ....
And the ambiguous abbreviations would all be a copy of some /_ambiguous_method
command.
/lorem
/sort <list>
Describe your idea
Job Queue is currently lost if Aqua turns off. While this isn't a problem for reminders that are only a few minutes after, it may be a problem for reminders scheduled to hours/days later.
Extra information
Suggestion: create a dump file once at the end of the JobQueue loop using pickle:
https://docs.python.org/3/library/pickle.html
Maybe use inspect.getsource
: https://stackoverflow.com/questions/12072252/cant-get-source-code-for-a-method-declared-through-exec-using-inspect-in-pyth
Alternatively, instead of each Job having a function to be executed, they could have a type instead (e.g. send_message
type), which are easier to store / load.
Describe your idea
Currently, when the user uses some ambiguous abbreviation (such as /s
, which could be /start
or /sort
), Aqua will warn them about it being invalid but will not say the available options.
safe_command: will ensure bot will only answer to the correct chat_id
Describe your idea
Currently Aqua requires you to log into Telegram, manually create your bot, manually set its token, etc.
It would be cool to have a client that does all this automatically (to allow you to talk to Aqua more easily): you log into it, then it will create the bot and put it up running for as long as the client is running, and then open Aqua's chat. This way Aqua would actually become user friendly as the user would not need to modify its config and run it manually.
Since the objective is to allow the user to talk to Aqua more easily, the client will only have Aqua's chat.
Extra information
The client could be a fork of https://github.com/telegramdesktop/tdesktop.
Probably create it in a different repo.
Before implementing this, read Telegram's client and API TOS to ensure this idea complies with everything.
Describe your idea
Instead of manually checking number of arguments in each function, add a decorator.
@num_args(0)
@authorize
def start(...):
...
Extra information
There are some edge cases:
remindme
, which requires at least 3)@num_args
means any number of arguments@num_args(X)
means exactly X arguments@min_num_args(X)
means at least X arguments@max_num_args(X)
means at most X argumentsDescribe your idea
Adapt GitHub Actions to use Poetry and then remove requirements.txt (also remove from CONTRIBUTING.md).
Also merge bandit workflow to run in the same workflow as lint/test.
Describe your idea
Aqua needs a message notifications system to send messages to the user without necessarily them being an answer to something. This could be useful e.g. for some important news, custom alerts at specific times of the day, etc.
Extra information
permanent
flag for each job. If the job is permanent, then it will always be re-enqueued. Then create some initializer to populate the job queue with the message notifications).config/message_notifications.json
file in which user will be able to pick the notifications they want to receive.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.