Posts

Showing posts from November, 2020

Testing, Testing, 1 10 11

Image
So Lab 8, never been this far behind so I got lots of work to do. Been a busy week and lots of assignments on the backburner, but I'm glad I got around to this one finally, it was a quite a doozy. For Lab 8 our professor has tasked us with implementing tests to our code. Testing our code? I thought I already do that, you know, with.. my eyes.. and brain. Well turns out that might not be the most reliable tools to test our code with, so we were to setup a testing framework to implement to our code to really analyse the different cogs and gears that build our code for any little mishaps or bugs. My program's test coverage This was kind of a difficult topic for me to grasp and took a while for it to really click in my head. Especially with aspects like mock functions, I was stumped. If we're not testing the actual modules themselves, what purpose does the testing have? Well from my bare minimal understanding, we want to treat the external modules like a black box that fit in o

Release 0.3 Part II : Cache Money

Image
In addition to a telescope issue, we were also tasked to contribute to another open source project in github. One that we previously worked on was also suggested. Now I would have taken the initiative to find another repo, and in fact I did find an interesting react app issue to work on, however due to time constraints from leaving this last minute, (consequences of bad time management, you'll suffer now AND later) I decided to revisit a repo I had worked on instead, and see if any issues exist that I may make a meaningful contribution on. So I went back to Survol, a chrome extension I had worked on a month ago during hacktoberfest and found a good issue.  Cache the changelog on onboarding page #141  So opening the settings/onboarding page for this chrome app will open a new tab with options to tweak settings and a change log on the right side documenting the additions to each version revision of the extension. This info is used through fetching the Github API. Everytime you open t

Release 0.3 : Telescope and The Quest for Infinity.... Scroll

Image
Welcome adventurers, sit down while I tell a little story of a brave programmer who slayed an issue so boldly, his PR request broke a record all time high of 57 comments. Alright so Release 0.3. Got it done right on time, just by the hair... I took on an issue on Telescope that was to add paging functionality to the search results, which also related to the another issue which is to enable infinite scrolling to the same component. Prior to this, humphd (our valiant maintainer and professor, whos been reviewing like a million PRs for the past few days.) has already added the SWR react hook to implement the same feature but on the home page feed. So I used that as a reference point. Issue #1222 I started work on the issue and first tried to implement the swr react hook with the current search components we had. This was confusing and tricky since with a search page we want to wait for the parameters for the search to be entered and then wait for the user to click the search button befor

Static Analysis Tooling

Image
With a small scale project that only involves a few coders, styling differences are a minor nuisance. But with a larger scale project involving more coders with different habits and stylings, the tab users and space users might start the next civil war of our time. Therefore we use static analysis tooling to moderate and standardize the styling used in a specific repo. This week our professor has tasked us with implementing static analysis tools in our link checking project. Before this lab, I've had prettier and eslint installed on my vscode as extensions but never fully understood and used them to their potential. But this lab cleared a lot up regarding these topics. So I installed prettier as a dependency and generated a config file with a few rules to test out Then I added a few files/directories to an ignore file to skip formatting some files. After that I tested out the formatting by running npx prettier --write . In addition to prettier, I also installed ESLint for further f

Lab 6 : Link Checking Telescope

Image
This week, we put our link checking program to use with telescope, an aggregated blogging site for all of the current and past OSD600 students dev blogs. Last week I blogged about working on the site by contributing to an issue. Our professor tasked us this week to check links for the 10 latest posts that appears in telescope using our link checking program from earlier this semester. So unlike the other students that haven't worked on telescope yet, which you can read about 2 posts back, myself (and a few others I expect) have already got telescope setup and have long since beaten that huge struggle. I'd look at the slack chat and I see everyone running into problems left and right, and man do I really feel for them. Took me a while to get it running initially, but fortunately I can go straight to implementing the link checking feature in my program. So I thought writing the feature would be fairly simple, and for the most part it was. First, using the api with the url 'lo

Hackvember-fest , PR#4.... days late + Conclusion

Image
A lot of tabs were opened today... And yes most of them were stack overflow threads, and react docs, and dev blogs, it was real satisfying being able to close all of them. However with all these information in aid for my quest to fix an issue, I've finally done it tonight. My 4th PR.... which is 4 days late. Oh well, I learned a lot today and that's what matters. So about 4 days ago I started working on an issue in this repo. It's called papercups and its an open source live customer chat web app, backend written in elixir, and frontend with typescript/react.  I found this repo a while back last month but was scared to touch it because of all the technology that built the app and it intimidated me. But with last weeks newfound confidence after setting up telescope and working on that, I was eager to try this out. So I found a relatively straight forward (yeah, right) issue to add an edit functionality to one of the pages for the customer data, and asked the maintainer if I

Hack.... vemberfest.. PR No. 3

Image
OK so this is pretty long overdue (sorry Prof!) And I still have one more pull request to go and that's on me yes. BUT, this week I spent working (or should I say learning) on our course's aggregated blog website which coincidentally, our prof is making us work on this week for the lab, so I guess I got a good head start going on.  So I took on an issue that seemed pretty straight forward in the repo. It was to change the functionality of the search bar when filtered by author. Seemed pretty straightforward enough, so I went ahead, forked the repo and cloned it on my computer. Now the reading begins, the lengthy process of coding. And the fact that this was a whole website coupled with different technologies that I'm not familiar with only made it waaayyy longer, which maybe is a sign that I should have started working on this much much earlier. But that's what happens when your time management skills is hot garbage. Anyways, I spent the next few days learning about eac