Friday, October 2, 2020

Lab 2 - feeling good about OpenSource

 Hey PC readers,

Welcome back to Week 3!

This week, we were supposed to make some Pull requests to our friends/peer's Release 0.1 project which is URL tester. It will check if the url is good or bad or unknown. Each of us added mandatory features and 2 optional features last week.

We had to add one more feature from optional feature list or one from our own. I went to find one project from Node JS in release 0.1 list and I found Ekaterina's project there.

https://github.com/egrinberg/Utest

Work I did on someone's repo: 

I forked her repo, cloned it in my local directory, and made a new branch called issue-2 (as per the lab 2 requirements). 

  • I went on to add a timeout feature in her code as it was waiting for long seconds to get the URL response. Since Node fetch does not have any explicit timeout feature, I wrapped fetch inside a timeout function to add timeout functionality. It is working well now with 3 secs timeout feature.
  • I also added "-V" option in her command list options to know about the version of the tool, in addition to the "-v" and "--version" she already had, for better user experience.(As I told in my previous blog, personally I always suffer from this, either to choose v or V). 
  • Node Fetch returns a promise which was not being properly handled, I added code to handle promise judiciously.
  • Also, updated the readme file.

 


After all this, I committed the changes and pushed it to issue-2 branch. I made a PR on her repo.

I am waiting for her reviews on this and work on them. Hopefully, it will be merged soon.

https://github.com/egrinberg/Utest/pull/3  


The work someone did on my repo:

Muskan Shinh did work on my repo and created a pull request with the following features:

https://github.com/chawlapalak/Url-Inspector/pull/7

  • Added Timeout of 1.5 secs to axios (Optimization)

  • Updated README.md to include this feature and elaborated on the existing features

  • Improved styling and indentation

    Review and Fixes:

    1.   I reviewed her PR request and I thought I should be able to see her branch if I pull the repository. To that, she replied on the PR, that we won't be able to see it like that and it should be this way.
    2.  So that was okay, moving on the next issue.There was a merge conflict in the ReadMe file. So I asked her to fix that and she fixed it.
    3. Next, there were some spelling mistakes in the ReadMe file so I put reviews on them and she fixed those.

    At last, I approved the reviews and merged the PR. Issue was closed with comment and PR was merged successfully. 

    That is all for today, Thank you for reading! See you next week.

    -PC

No comments:

Post a Comment

Lab 9 - The last chronicle

 Hey PC readers,  Welcome back to my channel! As the name says, this is our last lab of this semester Lab 9. In the last tale of the lighten...