Hello Readers,
This blog is dedicated to summarizing the progress of the first phase of Google Summer of Code 2024 for the Forum Revamp Project.
Currently, our forum is built using simple_discussion Rails engine, which lacks many features and is not actively maintained. The main goal of this project is to revamp the forum with new features such as a Markdown Editor for drafting forum posts, moderation tools, spam reporting features, a leaderboard for active forum users, and more.
So far, we have covered and implemented the following features in the first phase of the project:
For detailed implementation of these features do checkout the biweekly blog posts here.
These tests are crucial from the gem maintainer’s perspective as they help ensure that the gem is compatible with different versions of Rails. The Appraisal gem was already being used in the Rails engine but had not been updated for a long time. In weeks 1 and 2, I fixed the appraisal tests and updated them with currently supported Rails versions. During these weeks, I learned a lot about testing and debugging dependency version mismatch issues.
I also explored improving the development experience by integrating various tools like Solargraph and RubyLSP. With guidance from my mentors, I chose RubyLSP as it is more stable and actively maintained.
Since the forum is public, it is crucial to gatekeep inappropriate language. This problem is common in public forums where users sometimes use inappropriate language. To solve this problem, we used the language_filter
gem, which allows us to filter inappropriate words from forum posts.
The idea is to throw an error message to the user if the post contains any inappropriate language.
The following are some small UI-UX improvements we have made to the forum post card:
We have covered the language filter to gatekeep inappropriate language. However, there are still chances that users can post spam content since the language_filter
gem is not that powerful. To mitigate this, we implemented the Report as Spam feature. This feature allows users to report a post as spam. Once reported, the post will be reviewed by moderators.
To learn more about the implementation details, you can check out my biweekly blog post on my GSoC experience here. In the blog, I’ve discussed each aspect of the implementation in detail.
Currently, Slack is our main communication channel for both contributors and users. To keep the community updated about new forum threads, we implemented the Slack notification feature. This feature notifies the Slack channel about new forum threads.
It was fairly simple to implement, thanks to the noticed
gem and Slack webhook integration documentation. Every time a new forum thread is created, the Slack community will be notified.
This feature is significant as it allows users to draft forum posts in Markdown format. It can be useful for adding more features like embedding CircuitVerse circuits, tagging users, embedding YouTube videos, and more using Markdown syntax extensions. So far, we have added the Markdown editor without any extensions, which will be added in the next phase of the project.
Here is how the Markdown editor looks:
Week 1:
Adding supported Rails versions in AppraisalWeek 2:
Fixing CI failsWeek 3:
Adding language filters and UI changesWeek 4:
Report as spam and moderation review pageWeek 5:
Slack notification in specific channel for new threadWeek 6:
Markdown editor using SimpleMDEThe work of phase 1 focused on adding high-priority features to the forum like language filters, spam reporting, markdown editor, and Slack notifications.
In the second phase, we will focus on adding features like embedding CircuitVerse circuits, tagging users, etc., in the Markdown editor, and adding a leaderboard for active forum users.
More importantly, if time permits, we will consider republishing the Rails engine as a new gem with all these new features.
Following are the key takeaways from the first phase of the project:
git rebase
over git merge
for maintaining a clean git history.Over the past few weeks, I’ve had an incredible journey contributing to CircuitVerse. The community has been supportive and motivating, and I had the freedom to meticulously plan and execute my tasks, all under the helpful guidance of my mentors. I’ve learned a lot about the inner workings of Rails Engine, and I’ve gained a lot of confidence in my abilities as a developer.
I would like to thank my mentors, Aboobacker MK and Tanmoy Sarkar, for always being there to help me out and guiding me throughout this period.