Open source, Week 11
Second week of the open-source phase is over, and the lessons from last week made for a more productive and efficient week. Progress has been made, struggles have been had, and I still can’t figure out how to set up a Ruby on Rails project, so let’s jump into it.
The week started with some bittersweet news, as I got my first issue closed, but without making a PR request. After finding out last week of the issue regarding the batches updating in Mieilisearch and finding out it was a limitation of the API, a maintainer of the repo decided that the best option was to only include some documentation making it clearer that this limitation existed. That was a bummer, as I didn’t get to actually contribute with code, but the upside of this was the support and gratitude expressed by both the maintainer and the original user that raised the issue, as both of them thanked me for the work I put into researching the issue. While no code was uploaded, this made me feel a deeper connection and a greater appreciation of the open-source community, as they have opened their arms to an inexperienced developer as myself over and over again over the past two weeks. I leave this issue with no PR, but at least smile on my face.
The other more successful story comes from another JavaScript library called Math.js. When I found the issue, I got really excited, as although I didn’t really understand exactly what was going wrong, the owner of the repo had analyzed the issue and pointed out exactly what and where the issue was, leaving it open for anyone to take a shot at it. I jumped on the opportunity and quickly got to immerse myself in the library in order to understand what it did, how it worked and what exactly was causing the problem. While this library is huge and holds a lot of useful mathematical functions, the one I was focused one was its support of matrices, as the issue itself was one in which different representations of matrices gave different results, even though it was still the same matrix. To solve the issue, I first had to understand the concept of a sparse matrix, then I had to understand how this library handled such a matrix, afterwards I compared the way the function implemented the failing method (which was a replacement of a subset of the matrix) in both the dense and sparse format, and only then I was ready to tackle the issue itself. Solving it was a lot of fun, not only because I got to experience a lot of the internals of how a JavaScript library works and learn a lot more about matrices, but because of the unique challenges it brought that I hadn’t even considered before. Take for instance the fact that some of the unit tests crashed after my changes, which send me into panic at first. However, soon I realized that these tests failed because of the same issue I was trying to solve, so their failure was actually a good thing. However, the dilemma came from the fact that I couldn’t simply change the already established unit tests with no regard, as this seems reckless at best and malicious at worst. This had me analyzing the best way to both submit my change and back up the changes I made to the code, explaining my reasoning as clear as possible in order to accurately prove why the change was necessary. I learned a lot about JS, linear algebra, testing and communication from this, and although the PR is still awaiting review, I’m happy with all the work done so far.
Lastly, I want to talk about a failure I encountered this week, as I kept struggling to set up a Ruby on Rails environment of a simple issue in the Farmbot-Web-App project. This issue began the first week, but it has carried over to this past week, and although I’ve received help from my mentors and made progress through it, there are still some issues that prevent me from setting up the environment. On the positive side of this failure, I would like to pick up something positive, which is an advice given by one of my mentors: “If it takes you longer than a day and a half to solve, move on”. This might seem like an obvious sentiment, however as someone who is very stubborn and doesn’t let go of things he already started easily, this piece of advice allowed me to make this last week way more productive, as I realized I was blocked and moved on, at least for now.
Regarding other topics aside from open-source, this week some special circumstances presented themselves to me and my fellow apprentices, and this made it necessary for us to sharpen out computer science theory. This last week I dived into CS theory that, although it may be quite simple and basic from someone with a CS background, for me was all new ideas and concepts. A lot of the ideas and concepts I’ve studied, such as the 4 pillars of OOP, interfaces, constructor and the S.O.L.I.D principles; I realize now that I’ve been applying them to some degree for years, however I never truly grasped the concept or the reasoning behind each of them, so developing an understanding of the theory behind these practices has been quite enlightening.
To finish up, let’s summarize the work done over the last week:
* Math.js: The issue has been solved, the PR is awaiting review.
* meilisearch-js: After finding the root of the problem, the issue has been closed after deciding to only add some documentation to make clearer the limitation in the name of indexes.
* Farmbot-Web-App: I’m still struggling with setting up the Ruby on Rails environment, my plan for this next week is to try and set up a virtual machine and run a script provided for setting it up on Ubuntu.
Happy new year, may 2022 be filled of joy, surprises and opportunitites!