Week-2: Open Source Rocks!

jaladh-singhal
Published: 06/10/2019

Hello folks,

I am pleased to share that today my no. of contributions crossed 100! I know it's not a very big achievement, but atleast it gives happiness to a person who stepped in Open Source world, just 4 months ago. Thanks to Google Summer of Code 2019 ❤️

 

What did I do this week?

  1. I resumed my work on an old PR that integrates filter curves & information to our Sphinx docs by auto-generating them, each time docs are build. It is meant for providing a simple static interface to users in the docs itself. For this I'm using Jinja templating to generate Sphinx docs from the dataset.
    • I devised & implemented a better approach to integrate lots of data, by generating the required ~80 RST files at time of build, instead of storing them by defaut in docs/ directory.
    • By using Jinja, I converted Pandas dataframes (part of our dataset) into RST tables and made sure that filter tables appear in docs.
  2. Then my mentors told me to put it on a hold, and start working on setting up Azure pipelines for our repo. They are required for the Continuous Integration & Deployment (CI/CD), which are more prior than development for any project. Earlier we were using Travis for CI/CD but due to some of its shortcomings we decided to move to Azure DevOps. I was absolutely new to this, so my mentor told me to take help of another GSoC student - Youssef, who is setting up Azure pipelines for Tardis (another PSF SubOrg that my mentor is mentoring).
    • I created my Azure DevOps account, communicated with Youssef extensively for the Azure docs I need to read to understand this. He helped me a lot by providing his code & steps that are not listed in docs.
    • So after figuring out the process I needed to follow, and customizing his code as per our repository, I successfully setup both pipelines for our repo's fork. One pipeline is for testing (CI) and another is for building & deploying docs to GitHub pages (CD).

 

What is coming up next?

My mentor has already added me to our Org's Azure account as a member, so I will start setting up these pipelines for our main repositories - starkit & wsynphot. And if time allows, I'll resume my work on that PR to integrate filter curves in docs.

 

Did I get stuck anywhere?

While setting up azure pipeline for docs deployment, I felt quite stuck because there was so much new for me to grasp. The process required generation of SSH keys and setting up them with Azure by configuring variables, secure files, etc. of the pipeline. But by patient reading of Azure docs & clarifying my doubts with Youssef, I finished it up successfully.

 

What was something new and exciting I learnt?

📝 PEP8 (Python Styling Guide): While reviewing my PR, my mentor pointed out that I should adopt PEP8 style in my added code to maintain code consistency. I never knew that there exists some standard styling guide for Python. I read it, it explains really well about almost every formatting & styling choices we need to make in our code and which of them is preferable!

🔐 SSH RSA keys are used as authentication credential for single sign-on without needing username & password. I came to know about this while setting up docs deployment pipeline where we need to use SSH to push commits made by VM to our GitHub repo. These keys always exist in pair as a private key & a public key - I read about this past semester in my coursebook, but I understood it better when I implemented it.

❤️ Open Source = Fast Completion: This setup of Azure pipelines that I completed in only 2 days, could not have been possible if I was not working in an Open Source Community. As Youssef had already given enough time to figure things out and writing code for the pipeline, I need not to start from scratch. I used his code & quickly customized it as per our repo. I need to understand the process, I reached him & quickly got the relevant sources. A big thanks to him & the community. More power to Open Source!

 


Thank you for reading. Stay tuned to know about my upcoming experiences!

View Blog Post

Week-1: Mending the roads for smooth travel in subsequent weeks

jaladh-singhal
Published: 06/03/2019

Hello folks,

So the 1st week ended pretty quick and here I am to share my 7-day journey. The most shockingly amazing thing happened this week was that my mentors made me the member of our Org - StarKit. Now I'm not only a contributor but officially a collaborator! I am thankful to my mentors for believing in me. 😊

 

What did I do this week?

- I began with fixing issue in some of the filters we're using (problem in loading them) by writing code to clean the filter data. After several discussions with mentors, I finally ended up creating a new updated HDF file of filters - that works perfectly fine!

- Our Travis test builds unexpectedly began to fail - I identified it was due to a recent update in pluggy (used by pytest). So I created an issue on pluggy repository, their developers were amazingly fast as they fixed the problem within 6 hours.

- Updated codebase for the setup of doctr (to deploy our docs on GitHub pages directly from travis build).

 

What is coming up next?

This week, work was mostly inclined on fixing & setting things up. In following week, I'll most probably work on creating a static interface on our Sphinx docs that will let users to access required filter curves & information. Or if my mentors suggest to undertake something more prior, I'll work on that (since our package WSynPhot is in its initial phase - so I can't strictly go according to my proposed timeline).

 

Did I get stuck anywhere?

While setting up doctr - I got confused and mistakenly took the OAUTH key sent by my mentor as public key to put in Travis. Due to my PR, it got publicized! My mentor forwarded me the mail he got from GitHub about privacy leak and I realized what a blunder I committed! *facepalm*

But he was cool about it, said that it was a learning experience for me. So I created another PR for doctr setup, once he himself added newly generated public keys. We had some discussions about the uncertainities he had about my PR but I convinced him and it worked as expected. And viola! we got our docs deployed on github pages. Later my mentor realized OAUTH key was actually not required in the process and cleared the confusion for all of us. 😅

 

What was something new and exciting I learnt?

- Taking initiative to communicate: I reported issue 1st time to another org whose tool/service we're using (pluggy, and SVO from which we obtained unclean filter data) - my mentors even admired me for this!

- HDF5 files (a way to store & organize large amount of data hierarchically in groups): Understood about how they organize data while investigating erroneous data in them and reading/writing them using pandas and h5.py

- And the biggest thing - Keeping Patience: Sounds pretty obvious to already have. But no! when you work in a team, you become very eager to hear from other members, so that you can proceed and quickly finish your work. As my mentors are astronomers by profession - they remain quite busy in their work & conferences. So I've learned that it is OK to wait (get involved in something other than this project) before you hear back from them, even if it takes a day. But that is for sure that they do follow up when they become free. So keep patience & stay calm!

 


Thank you for reading. I'll get back to you next week with my new experience & exciting learnings. Stay tuned!

View Blog Post

Summer Begins!

jaladh-singhal
Published: 05/27/2019

So after 3 weeks when GSoC'19 results were announced, Coding Period has finally arrived - the Summer of Google Summer of Code has began!
It had been an incredible journey so far, with lots of learnings and lot of struggles. What was a dream for me in Jan'19, became an unbelievable reality at May 6 (the D-day when results were declared). It was a thrilling experience for me, a Sophomore, to get selected in GSoC'19 at PSF, who just stepped into Python last year. I've shared this exciting journey from my dream till reality in a dedicated article:
https://medium.com/@jaladh_singhal/gsoc19-from-dream-to-reality-3bf07d6f17bb.

Besides being Pythonista, I'm an Astronomy enthusiast, that's why I chose the PSF SubOrg - StarKit: A Python package for Stellar spectroscopy. This Summer, I'll be developing interactive analytical interfaces to visualize the Filter Curves of our package wsynphot. These interfaces will not only be able to auto-generate the Filter Curves but will also calculate the Photometry of Stars. The purpose is to make it easier for Astronomers to access the info they want within couple of clicks. Sounds cool! Right?

You can find details of my project idea at GSoC 2019 Projects page and package I'll be working upon i.e. wsynphot on GitHub page of StarKit. Within the Community Bonding Period (last 3 weeks), I was busy in my exams but I still managed to attend a Video Telecon with my mentors to discuss about a multiple things, from working in Community to the interesting work my mentors are doing in the field of Astronomy. They are really cool people - one of them is researching on Supernovae and another on nuclei of Galaxies & Black Holes!

As the Coding Period has began from today, I'm pumped up to start working on my project; to learn lot of things by implementing them - the real essence of Open Source. And Astronomy is already fueling my excitement! Stay tuned with me for this exciting journey, more posts to come. :D

View Blog Post