This document summarises the work I did as a student developer at Zulip organization, as part of the Google Summer of Code program.
Zulipbot Action is a project which I started in February, from scratch, aiming at redesigning the existing Zulipbot, the workflow-optimizing bot by Zulip, which helps Zulip maintainers in managing and monitoring the issues and pull requests across Zulip repositories, and hundreds of contributors at Zulip by providing them with a better workflow, like allowing them to self-assign and label issues, notifying them of merge conflicts, inactivity, issues opened in their area of expertise and much more.
While redesigning the bot, the aim was also to transition it from a self-hosted version built in Node.js and Express.js to a GitHub Action built in TypeScript. This transition would not only make it easier for maintainers to add and reconfigure the action as and when required but would also allow other organisations and projects to use Zulipbot and all of its features, with the ease of just adding a few workflow files in their repositories.
The complete Zulipbot Action is sub-divided into 4 actions, namely, commands-action, areas-action, activity-action and pulls-action.
commands-action allows the contributors to self-assign an issue they are interested to work on and start working on it on the go, without the need of waiting for a maintainer to assign them the issue, before they can start working on it. Not only this, it also allows the contributors to abandon an issue, if they no longer wish to work on it, and add/remove labels on issues/PRs (with some restrictions).
areas-action helps notify the teams in a GitHub organization whenever a new issue or PR is opened in their areas of expertise, by subscribing them to that issue or PR. It also helps organize the complete project into a few well-defined areas and keep track of the progress being made in those areas.
activity-action keeps a track on all the open issues and pull requests of a repository, and if any issue is found to be inactive for more than a specific number of days (neither the issue nor the PRs linked to the issue have been updated for more than the specified days), it posts a reminder to the contributor assigned to that issue (by commenting on the issue), and automatically unassigns the contributor from the issue if no progress is made for a specific number of days even after the reminder.
pulls-action provides a bunch of features to improve the overall workflow for both the maintainers and the contributors while working with PRs.
It helps maintainers in prioritizing the PRs to review by labelling each PR with a size_label
according to the size of the PR, which gives a rough idea on how much time it might take to review a PR. It also allows maintainers to automatically copy certain labels (as specified in the configuration file) from issues to PRs whenever a new PR is opened and is linked to an issue.
Along with this, it also provides a feature to notify the contributor working on a PR whenever a merge conflict occur on the PR, so that they can resolve it as soons as it occur.
Repository: https://github.com/garg3133/zulipbot-action
My second project was to build an import tool for organizations who wish to move their teams, along with all of their data, from Rocket.Chat to Zulip. But as Rocket.Chat does not provide any export tool, I had to build an import tool which could extract all the data from the database dump of the Rocket.Chat workspace and convert it to the export format of Zulip, which then could be easily imported into a new Zulip organization by using Zulip's high-quality import tool.
- Add
pymongo
dependency to be able to read the mongodb database dump (bson
files). (c1885c1b) - Shift
mattermost_user
to a more genericuser_handler
file. (a21a2800)
The first PR on Rocket.Chat import tool (#18996) added the support of importing the following data from a Rocket.Chat workspace to the new Zulip organization:
- All users
- All public/private channels
- All teams and its public/private channels
- All discussion rooms as topics in their parent channel
- All the messages in all the channels
- All private conversations
- Reactions on messages (except for custom emojis)
- User mentions in messages (except
@all
,@here
mentions)
Commits
- Add Rocket.Chat import tool. (24dd0ff9)
- Document Rocket.Chat import tool. (e68b1989)
- Add huddle import support for Rocket.Chat. (044fe547)
My next PR on the project (#19461) added the support for importing all the custom emojis and attachments from the Rocket.Chat workspace to Zulip. Along with that, it also added the support for linking the channel mentions in the imported messages to the imported channels, which was missing before.
Commits
- Import custom emojis from Rocket.Chat. (65e28907)
- Import attachments from Rocket.Chat. (aed4e48d)
- Fix channel mentions in Rocket.Chat import. (54452fef)
PR #19564 adds the support for importing the threads in Rocket.Chat as separate topics in the new Zulip org, instead of just importing them in interleaved fashion.
Along with this, it also adds the support for importing wildcard mentions (@all
, @here
mentions) and does a few other bug fixes.
The PR is still under review.
PR #19553 fixes the issues with rendering of user mentions, stream/topic mentions and custom emojis inside the imported messages. While all these things were imported correctly before, these were not rendered properly in the messages.
This PR is still under review.
Zulip Repository: https://github.com/zulip/zulip
My Commits: https://github.com/zulip/zulip/commits?author=garg3133
Merged PRs: https://github.com/zulip/zulip/pulls/garg3133?q=is:merged
Open PRs: https://github.com/zulip/zulip/pulls/garg3133
Below are some other contributions I made to Zulip during my GSoC coding period, apart from the projects I was assigned to.
PR #19034 added the support for importing all the attachments, while migrating from Mattermost to Zulip.
- PR #19266 fixed a bug which made the top controls of compose box hide behind the header, in the presence of a navbar alert.
- PR #19270 fixed the mis-alignment of the top-right compose-box buttons.
- PR #19321 fixed a bug which caused the size of the compose-preview box to remain small even in the expanded mode.
PR #19436 added an improvement in the existing Slack import tool to uniquify the generated email addresses of the imported slack bots, using a class-based approach. This ensures that the email address of no two slack bots conflict with each other.
Both of my projects have some follow-up work left, which needs to be done in the post GSoC period.
While the first three actions, i.e., commands-action, areas-action and activity-action are complete now, there are still a few features which are left to be implemented in the pulls-action, like copying the labels from issues to linked pull requests. I plan to implement these in my free time after GSoC, and also to keep on maintaining this project and help with any issues or bugs that may occur during the deployment of this action in various Zulip repositories.
There are still a few small things left to be added support for in the Rocket.Chat import tool, like importing default streams, starred messages, etc. I intend to add support for all these things as well in the Rocket.Chat import tool in the coming weeks and be active with reviews in my open PRs.
I intend to stay connected with the Zulip organization even after the GSoC period is over and be active with the reviews on my open PRs and a few follow-ups which needs to be done in both of my projects.
I am really grateful for the great learning experience I had since the start of my journey with Zulip last year, which definitely helped me become a better developer and I'm looking forward to stay engaged with the amazing Zulip community and help out as much as I can.
Respect Sir,
I'm Siddharaj Yadav a computer engineering undergraduate, Pursuing TE at D Y Patil College under (Pune University).
I am new to open source contribution but I am well aware of Python,Django,HTML and Git& GitHub. I would to contribute to your organization but could you please tell me how to get started? Gsoc
Hoping to hear from you soon
Regards
Siddharaj Yadav