Things I Learned Through My First Hacktoberfest Pull Requests!
Tags: opensource, hacktoberfest, beginners, python
Published: 2022-10-16 05:13:39

After searching for the perfect issues to solve as part of [Hacktoberfest](https://hacktoberfest.com) for about 10 days, I finally found them! Anyone participating in Hacktoberfest knows how hard it can get to find issues to contribute to. Issues are usually either taken or lack proper documentation to set up the development environment, or they may be something completely beyond one’s abilities. 

The number of things I learned over the three pull requests I made this week was beyond expectation. I was also able to network with maintainers and nonprofit organization founders who are taking part in Hacktoberfest. I was able to directly communicate with some of them through Discord and I even got invited to a standup meeting of a [Non-governmental organization (NGO)](https://en.wikipedia.org/wiki/Non-governmental_organization) called [Glific](https://glific.org) to understand their issues for better contribution. Never in my wildest dreams did I expect so much networking and collaboration to happen within just the first 15 days of Hacktoberfest! 

I learned that open source is a wonderful way to gain new skills and people are more than happy to guide you when you are stuck. 

# My Pull Requests 🌟

## 1. intel / cve-bin-tool 
I created two pull requests for Intel’s [CVE Binary Tool](https://github.com/intel/cve-bin-tool). CVE Binary Tool is a tool that scans a file for known [Common Vulnerabilities and Exposures](https://en.wikipedia.org/wiki/Common_Vulnerabilities_and_Exposures#:~:text=Common%20Vulnerabilities%20and%20Exposures%20(CVE)%20is%20a%20dictionary%20of%20common,publicly%20known%20information%20security%20vulnerabilities.).

- [Pull Request 1](https://github.com/intel/cve-bin-tool/pull/2123) - `refactor: resolve mypy errors in test_version.py` 

- [Pull Request 2](https://github.com/intel/cve-bin-tool/pull/2124) - `refactor: resolve mypy errors in test_extractor.py`


## The Fix 🔧
I was able to fix the errors that were occurring in both issues and now I am awaiting approval from the maintainer. 
- [Fix 1](https://github.com/intel/cve-bin-tool/pull/2123/files)
- [Fix 2](https://github.com/intel/cve-bin-tool/pull/2124/files)


### Challenge Faced: A CI/CD nightmare 💭

Now, the only little knowledge and experience I have of CI/CD are from my cloud computing class where we used [jest](https://jestjs.io) to write tests. I woke up to two emails stating that my run failed for both pull requests. It had something to do with [`black`](https://pypi.org/project/black/). Not knowing what it meant, I promptly sat to work to identify what went wrong. This was also the first time I properly learned to read those logs that shows the CI/CD runs. Black was checking for whitespaces and it was unhappy with the whitespaces that I left in the code. I had to go back and run `black test/test_extractor.py` to fix the formatting. 

I received some requests for changes from my reviewer for the `test_version.py` file. The comments were super detailed and so helpful. I knew exactly what I did wrong, fixed them, and pushed my changes. 

But then... the run failed again and it had to do something with [`isort`](https://pycqa.github.io/isort/). Through this trial and error of multiple runs fails, I learned that there was something called [pre-commit](https://pre-commit.com) that checks a whole lot of things such as formatting and linting and most of my fails were formatting related. I then ran the pre-commit and fixed all errors before pushing my changes. Had I read their contribution guidelines a bit more carefully in the beginning, this would have been a lot easier.

## 2. ifmeorg / ifme 

[If me](https://www.if-me.org) is a mental health organization that encourages people to share their stories, moments, and moods through their platform with their loved ones. I found this organization through reading this [GitHub blog](https://socialimpact.github.com/insights/hacktoberfest2022-dpg-volunteer-opportunities/) encouraging people to participate in contributing to digital public goods. If-me is a certified digital public good and I wanted to play my small part in helping them out. 

- [Pull Request](https://github.com/ifmeorg/ifme/pull/2171?notification_referrer_id=NT_kwDOBEOesrM0NTk3NDQ2MjAwOjcxNTQwNDAy) - `make the navigation bar fixed` 

### Challenge Faced: Lost in the Ruby codebase 

The development environment setup took a long time. The language used was Ruby and I had never seen Ruby code before working on this project. It was hard to go through the files to identify which file the issue was at. The issue itself was not very difficult but what made it challenging was my lack of knowledge of Ruby. Also, real-world projects are so large! It is hard to set them up and navigate around them to fix even the smallest issues. 

Currently, I am addressing the changes requested by the if-me maintainer and I am also attempting to write some unit tests for them. Now, it has only been about two weeks since I learned to write unit tests, so I am not so sure how this will go.

# Digital Public Goods 

## What are [Digital Public Goods](https://socialimpact.github.com/insights/what-are-digital-public-goods-and-DPGA/) (DPGs)? 

>“Digital public goods are open-source software, open data, open AI models, open standards, and open content that adhere to privacy and other applicable laws and best practices, do no harm by design, and help attain the [Sustainable Development Goals](https://sdgs.un.org/goals) (SDGs).” (Digital Public Goods Alliance) 
>

NGOs are very close to my heart. Going into Hacktoberfest I knew one thing – I wanted to help small non-profit organizations that are working for a good cause. I wanted to make an impact – big or small and come out of Hacktoberfest feeling accomplished. I love participating in events that are working to achieve Sustainable Development Goals and I love reading research reports on how open-source software or technology is being used for social impact. [Here](https://socialimpact.github.com/insights/oss-india-kenya-egypt-mexico/) is one such great article!

Before joining Seneca College in 2020, I spent about 1.5 years working and writing grant proposals for various NGOs throughout Southeast Asia and the Pacific Region remotely. I wrote for and provided technical support to six organizations in Thailand, Myanmar, Indonesia, Papua New Guinea, Mongolia, and Bangladesh. My writing became the voice for those who did not have the skills to write grant proposals. I told their stories, helped them prepare reports, and infographics, and even filmed and edited short documentaries for their donors. When I found the GitHub blog mentioning all the nonprofits taking part – I knew I had to help them in any way I could. This time through code. 


### A little bit of backstory…
My mom runs a nonprofit research center in Dhaka, Bangladesh focusing on marginalized communities and finding ways to serve them better by regularly collaborating with the nation’s government and various universities from around the world (particularly Europe) for research purposes. My dad does the same thing, but in Bangkok, Thailand and oversees the activities of many NGOs across ten countries in Asia and the Pacific region. This exposed me to the world of nonprofits from a very young age and naturally, I was inclined to participate in helping them. 

# Going Forward 🚀
I can't even begin to describe how much I am enjoying taking part in Hacktoberfest! I am becoming a better programmer and learning so much. I will be writing more blogs about my experience and the projects I am working on in more detail in the coming days.