python-zulip-api
python-zulip-api copied to clipboard
zulip_bots: Add a script for creating Zulip bots.
Following support to running bots from entry points in #708, we
implement this create-zulip-bot
tool to simplify the process of
creating new bots. The user will be able to directly install the package
with pip and run the bot with zulip-run-bot
, or use it to quickly set
up a git repository.
Note that the boilerplate generated by this script does not contain
tests.py
yet. We need to figure out the right pattern for integrating
unittests for such packaged bots.
Can you explain the motivation for the first commit? I can imagine a world where one would prefer to find a bot using a specific path, and don't have a clear idea of whether there's any potential situation where we might prefer semantics of "Please only use a bot from the registry". Maybe the right thing to do is add a docstring in the bot discovery function explaining clearly the sources it looks at the motivation for why they're prioritized the way they are? That seems like a good resource in general and in particular would make it a lot easier for me to review this change.
@PIG208 This looks like it needs a rebase and tidy, but otherwise would progressing this be easier if the two commits were split between PRs? The first commit isn't necessary for the second, right?
Heads up @PIG208, we just merged some commits that conflict with the changes you made in this pull request! You can review this repository's recent commits to see where the conflicts occur. Please rebase your feature branch against the upstream/main
branch and resolve your pull request's merge conflicts accordingly.