DEV Community

Cover image for My Hacktoberfest Adventure: Contributing to freeCodeCamp’s Developer Quiz Site 🚀🎉
Tasbi Tasbi
Tasbi Tasbi

Posted on

My Hacktoberfest Adventure: Contributing to freeCodeCamp’s Developer Quiz Site 🚀🎉

October brings colorful leaves, pumpkin spice everything, and for developers—Hacktoberfest! This was my first year diving into the open-source waters, and I decided to tackle a really cool issue in the freeCodeCamp Developer Quiz Site. Let me take you along my journey of what I contributed, the obstacles I faced, and the thrill of watching my pull request (PR) move toward merging!


How I Found the Issue

After browsing through different repos participating in Hacktoberfest, I came across freeCodeCamp’s Developer Quiz Site. This repo is dedicated to building a comprehensive quiz platform to test developers on various topics. There was a specific issue, #1135, that caught my attention: expanding the security questions for the platform.

Finding the right issue wasn't easy. It took a lot of digging and browsing through various projects, but finally, I landed on this one. Perfect! I’m passionate about cybersecurity, and this was an opportunity to flex my knowledge while contributing to something meaningful.


The Contribution: Adding New Security Questions 🛡️

The task was to create new security-related questions that weren't already present in the repo. I took inspiration from the incredible freeCodeCamp News articles on security and added questions covering topics like DNS poisoning, SQL injections, phishing attacks, and even fun trivia like "What does GPG stand for?" 🎯

Example Question I Added:

{
  Question: "What is the main goal of DNS cache poisoning?",
  Answer: "Redirecting users to malicious websites.",
  Distractor1: "Encrypting DNS queries.",
  Distractor2: "Speeding up DNS resolution.",
  Distractor3: "Blocking access to specific websites.",
  Explanation: "DNS cache poisoning allows attackers to redirect traffic to malicious websites by tampering with DNS data.",
  Link: "https://www.freecodecamp.org/news/what-is-cache-poisoning-and-how-to-avoid-it/"
}
Enter fullscreen mode Exit fullscreen mode

All of the questions were submitted in the required format, with the answer options, distractors, an explanation, and the source link. It was important to check that the questions hadn’t already been added and were following the guidelines from the CONTRIBUTING.md.

The Dreaded Failing Test: Debugging with a Smile 😅

Once I submitted my PR, everything looked good. Then came the bombshell: “Some checks were not successful” in my GitHub Actions build. 😱

The test failures were due to issues with the properties in the quiz questions, particularly the Distractor1 field. It looked like I had missed something small but crucial. This is where the real learning began! After reading the error logs and getting to the root of the issue, I jumped back into my code and fixed the problems.

Here’s what the error looked like:

Error: expected {...} to have property 'Distractor1'
Enter fullscreen mode Exit fullscreen mode

A few tweaks and pushes later, the tests were green, and all was well in the open-source universe again!


Submitting the Pull Request 💻

With the issue resolved, I went ahead and submitted the PR. Since this was part of Hacktoberfest, I made sure to kindly ask the maintainers to label my PR with “hacktoberfest-accepted,” ensuring my contribution would count. It felt like crossing the finish line after a marathon! 🏁

Here’s a snippet of the PR description I wrote:

Summary of changes: Added several new security-related questions for issue #1135. Since this contribution is part of Hacktoberfest, could you please consider adding the hacktoberfest-accepted label if this PR meets the criteria? This would help it count toward Hacktoberfest contributions. Thank you!

Lessons Learned Along the Way 📚

  1. Read the Contribution Guidelines: Seriously, it saves so much time. Each project has its own set of rules, so make sure to follow them to avoid PR rejections.
  2. GitHub Actions Are Your Friends: The automated tests might be a bit intimidating, but they’re actually lifesavers. They caught my mistakes early, so I could fix them before the maintainers even saw my PR.
  3. Community Matters: Contributing to an open-source project isn’t just about the code—it’s about being part of a community that’s constantly improving. The feedback loop from maintainers and fellow contributors is invaluable.

What’s Next? 🚀

Now that my PR is submitted and tests are passing, I’m keeping an eye on the review process. The maintainers may have some feedback, so I’m ready to make further adjustments if necessary. In the meantime, I’m already thinking about what my next Hacktoberfest contribution might be!

So, if you’re thinking about joining the Hacktoberfest fun—go for it! There’s no better feeling than contributing to something bigger than yourself and seeing your work go live for the whole community to benefit from. 🌟

You can follow my progress and check out the PR I submitted here.


Have you participated in Hacktoberfest yet? Drop your favorite repo to contribute to in the comments below!

Happy coding and happy Hacktoberfest! 🎉👾

Top comments (2)

Collapse
 
daniel_mccallum_0e7a67117 profile image
Daniel McCallum

Great job! This really helps me understand what the process is like.

Collapse
 
tasbi03 profile image
Tasbi Tasbi

Thank you so much, Daniel! I'm glad the post was helpful to you. Contributing to open source can feel overwhelming at first, but it's really rewarding. Best of luck on your coding journey!