How to get started with contributing to OpenSource?
This article is oriented towards Python projects but the tips are transferable
I get this question a lot and every time I answer it on a one-off basis, I feel a twinge of guilt as I realize it’s only a matter of time before someone else is going to have this question and I will likely leave them hanging for a long time before I can get back to them with tips. Hopefully I can remedy parts of the guilt with this article.
First of all, what is OpenSource?
If you intend to contribute to Opensource, you probably already know the answer, but for those who don’t - Opensource, in my interpretation, is an adjective for a product or a service whose internals are visible to the public for viewing, contributing and based on its license, for modifying and distributing. It is also a word used a lot as a shorthand for OpenSource Software (OSS). For the remainder of this article, I will refer to OSS as OpenSource.
Between this and the official definitions scattered on the web, I think we can safely move on.
How do I find projects?
a) Github is a great way of finding projects based on your interests - by way of application or language. Check out https://github.com/topics
If you’re looking for Projects using Python, then filter in Topics by Python and browse through the different packages there. If you’re looking for a specific topic like “Astronomy” or “Testing”, then you can’t go wrong with a basic search - https://github.com/search
b) There are also a bunch of topics that are created just for first-timers to OpenSource contribution :
c) Thirdly there are a few aggregator sites that have aggregated projects that have issues for first-timers -
d) Look at all the libraries you use on a day-to-day basis. Identify one or more of them that you resonate with and are happy it exists. Try and find it on Github and follow the steps in the next section. (For me, one of my favorite packages is pandas-profiling. You might have seen that from one of my previous posts.)
e) Create your own!
Once you’re familiar with the process of Forking a repository, submitting a PR etc, find an application that you can create to use for yourself and probably a few of your friends and start finding issues in it that you can invite your friends to fix and solve yourself as well. After all, there’s nothing that says that contribution to opensource Has to be to projects that aren’t your own!
But what counts as a contribution to Opensource?
Everything counts! But what is everything?
Let’s consider an OpenSource project on Github. Say plotly. Now the plotly.py project has a bunch of components in it -
- Documentation (Readme.md etc.)
- Source Code
- Issues (1.2k as of this writing)
Each of these elements are fair game as far as counting as contributions to OpenSource goes. It does Not have to be only code contributions.
a) Let’s say you’ve set up the package on your local machine and you found the README.md tedious in terms of how you had to install the whole thing. If you’d like to improve the documentation and make it simpler for later users, you can potentially contribute there!
b) If you’ve found a bug in the library during your usage of it, you can raise an issue and have one of the maintainers check it out. Improving the quality of the package is a great way to contribute to OpenSource.
c) If you’re a user of the project and let’s say you understand the usage enough to help Troubleshoot issues, you can check the Issues tab out on the project and answer people who have raised them! That way, you’re easing the pain of the maintainer and also helping the person who raised the issue. Sometimes the resolution is as simple as pointing out an error in the user’s usage of the library. And sometimes, it might need a code change and a Pull Request.
d) Create resources around the packages you care for in terms of blogs and videos and let the maintainers know! Most people are happy to let your work be included in the Resources section of their projects.
Is there a “code” to contribution?
Pardon the pun. But yes, there is a code to contribution that all contributors must follow.
Don’t contribute for contribution’s sake. In the sense that, if your motivation is to get a Hacktoberfest tee-shirt etc., while that is a valid motivator, the contributions must add value to the project in at least some form. I’ve seen a lot of trivial contributions over the years where users will try to rack up contributions by way of correcting a single character in the documentation where there was No change required and think that will count towards their participation in Hacktoberfest. Not only is that unfair to the project, it’s unfair to you as a contributor. Real value can always be provided, as long as you’re ready to put in the work and just look a little harder.
Look for a “Contributions.md” file in the Project’s repository. These files typically chalk out a set of guidelines particular to that project.
Finally, Have fun :) Contribution shouldn’t feel like a chore. You should be able to enjoy the process.
A little something extra…🎉
If you’ve stuck around to the end of the article, you’re obviously interested in contributing to OpenSource. I have a little exercise for you.
Here’s a repository I’ve created with a couple of source code files, some documentation etc. - https://github.com/everythingpython/opensource_playground.
Now, I will keep adding more files to this “playground”. For now, let’s work with the files that are present. Go through the README.md file in the repository and follow the instructions to start your OpenSource contribution journey :) If you have any doubts/issues, mail me your query at email@example.com !
More Reading -
Thanks for reading Everything Python! Subscribe for free to receive new posts and support my work.