I wanted to write this blog post on a triumphant, feel-good haze of power from smashing my biggest hurdle yet. However, I'm actually pretty behind on my open-source classwork.
I'll admit I started a little late, as my mid-point blog post laments, and the last night of work has been stressful, but I think I won't mind too much.
Not to say I won't miss the marks - but I'd be remiss if I didn't admit that the real reason I took this class and stuck with it was because it was a new experience that let me learn so many new things that I can apply to life as a developer.
I encourage you to read that mid-point blog post as well because it highlights everything I did while working on this pull request with a couple of exceptions I'll discuss here.
Building
My biggest fear was also my most correct prediction: working within other developers' codebases would be the most difficult part of this endeavor. I think figuring out that getMice
leads to getSearchedEntity
which then sends the info back to sendInteractiveSearchResult
which then uses formatMice
to build a table which then finally prints the message out for the Discord bot to say was a very difficult line to follow and I think it really highlights how starting early on something like this can help. I think that if I had started even a few days earlier, I would've had this line figured out and could've plotted my own with my own functions much sooner and with greater confidence.
The other difficult part of writing this feature was the testing. Frankly, working with testing frameworks has been the bane of my existence. I finally got used to Jest and now there's a whole other one I have to learn! Truly exhausting.
But seriously, the most difficult part of working with another developer's code is that it's their code. And it really makes the most sense just to them.
So if you remember from my last post, I described where I needed to go with my code.
The process is similar to the code in the other commands, it will include a way to search the agiletravels database for the correct item, then print a list of items that can be found in it for the user to peruse. Seems pretty easy right?
This is basically what I did, but following the lead with other code blocks, I created my own line through the program to get me to print out my own table of items. It turned out to be not that hard and I almost feel proud that I managed to get it working with relative ease.
I started this post by lamenting that I wanted to feel triumphant about my work, but to be quite honest, I am. I think that creating a feature like this to add to a program that with sit in dozens of discord servers and maybe be used by hundreds of people - I think it's a really great thing and I'm really happy to have developed a feature like this. If you want to take a look at the pull request and see how I'm doing you can look here.
I think the biggest thing that I missed out on was leveraging the open-source community, especially the one in the OSD600 slack channel. Everyone there is quite adept and is always working on stuff. Though I never really felt like I need to ask any questions, I think doing so would've helped me out in a lot of places.
Lessons
So before I close out this blog post, I wanted to talk a bit about what I learned. Not just that other peoples' code is hard to read. But more about what I learned about collaborating and the technical aspects of open source development.
One thing I learned is everyone on GitHub is always trying to be polite but sometimes just can't help themselves.
Also that while git just loves to screw up your line endings, it's really the repo owner's fault if they don't have a code formatter that runs before each commit isn't it?
Or at least, if git does go ahead and ruin your line endings, you can at least roll back and force push the good version.
Actually, nevermind that one.
I think as I get better as a developer I'll have a little more confidence and be a little more open about asking for help from others but for now, the biggest learning experiences have come from learning how to work the robust architecture of git and using ti to work with so many different people and I can't wait to apply it to my next project.
Top comments (0)