I have been contributing to VLC-iOS for about 7 months now, and it's been an amazing ride. I have learnt a lot and grown a lot as a developer. I started contributing to VLC because I wanted to work on an open source project in iOS which had a massive user base and was meaningful to me (I am an avid user of VLC myself). I started exploring VLC-iOS issue board to find something that I could fix/improve with not much familiarity with the code base.

I found a relatively simple issue and created a merge request. Eventually, it was merged and my feelings regarding the merge could be summed up pretty well in the following tweet.  

I kept contributing to VLC while looking for a summer internship. I always wanted to participate in GSoC but at that time, I didn't gave it a serious thought. And the chances of me getting in, especially under one of the most well known organisation in open source was very slim.  It could be possible that VideoLAN did not participated in GSoC this year, or Google didn't selected it to favour some new org/project, or VideoLAN didn't have enough slot for iOS projects, or my experience with Swift and my project proposal wasn't quite what the mentors were looking for. I didn't wanted to put all my eggs in one basket, like I did last year when I tried for GSoC and end up with no good option for summer internship.

This being an article for the Final Evaluation for GSoC, you know I made it. I wanted to write this article in such a way that a person who has not participated in GSoC could know experience what's it's like to be a student developer in Google Summer of Code under VideoLAN.

We begin with the community bonding period. For me it was pretty silent (way more than I initially had thought. I joined GSoC students discord, tried to become more active on VideoLAN IRC. I did made that "mandatory" LinkedIn post about my acceptance into GSoC.😜. I did got on-boarding emails from Jean-Baptiste Kempf (org admin for VideoLAN). All in all, it was quite a fun and chill time.

The contact with Soomin Lee (my main mentor for the GSoC period) was delayed until the first week of coding period. We decided the best way to start with coding was to get me familiar with the VLC codebase even further by solving some more issues.  

When we finish our work for the day, we had to send an email to mentors and admin to update them about the work we did and problems we faced that day. Instead of adding a new subject, after few days, I started naming them Daily Dispatch (name inspired by Austin Kleon's book Show Your Work) followed by the date of the day. Which coincidently I am finding really helpful right about now to write and relive my last 12 weeks of the summer.

The first week of GSoC coding period overlapped with Apple's WWDC. Since, in the beginning, I didn't had much contact with the mentor, I took that time to learn Apple's new framework and Swift language improvements, while working on some basic issues in VLC. I learnt about Group Activities framework (SharePlay), Swift Concurrency, DocC, ARC in swift and more. I wanted to implement SharePlay in VLC, and I tried figuring out if custom players like VLC could use it and it probably can. I proposed this idea to my mentor, they said if we completed the things in proposal early, we could work on it but it wasn't a priority at that time.

I also had my end semester examination in the upcoming week, so I informed my mentor and focused on the examinations. In the third week, I created my first GSoC merge request. The merge request fixed a bug in which the Cast UI was not hiding when media was not playing on the external screen. And created the following new issues:

As discussed in the weekly meeting, I started working on issue #1141, the continue watching screen. This would become the major feature I would work on during my GSoC. I have never worked with CollectionView before, so this was a first. Additionally, I had to implement the collection view in such a way that the first section moved horizontally while the second vertically (which for all intensive purposes, I intentionally ignored at the beginning).

To start to develop the Continue Watching, I started exploring VLCMediaLibraryKit which handled all the media library amongst, more importantly for me, the historical data and progress for the media in VLC. With some help from Felix Paul Kühne, I figured how to access VLCMediaLibraryKit object in VLC-iOS app.

I started with developing cells for the continue watching collection view. I prefer storyboards to programmatically, so I made the cells in the former. It took me fair amount of time to figure out how the collection view was being populated. But when I did, the implementation is quite impressive. In the data source for the collection view, we are getting the media cell and updating it's media object and in the DidSet for the media object, we have multiple functions depending upon the media type populating the UI Elements.

After I had my initial XIB for Continue Watching ready, Edgar Fouillet (my second mentor) and Soomin had a meet to figure out how we should approach the multidirectional collection view. We were thinking of hacking it together with collection view inside a collection view but then Edgar found this article.

It shows how we can set up collection view flows differently for each section. Since we only had requirement for 2 different section, implementation was simpler compared to the article. At this point, I really dove into all the collection view stuff and tried understanding how it worked and how it has been implemented in VLC. I followed this post from raywenderlich to learn about collectionview. I had some prior experience with tableview so understanding collectionview was relatively simple.

It took me few weeks to implement the Continue Watching section. Initially I was coding for the continue watching to be visible on both Grid and Non-Grid view. But later mentors decided it would be good enough to show it in only grid view. During all this, I also did worked on some AutoLayout bugs reported in the issue board.

Here is what continue watching screen looks like

I tried integrating historical data from VLCMLKit but there seems to be some bug with it. I was asked to ignore it for a while and focus on testing and fixing UI bugs. After which I have plans to add some UI/Unit tests for continue watching. I am working on finding and fixing UI bugs, as I write this article.

During my first week of working on Continue Watching, I did open a draft merge request so that I my mentors know and can recommend any code architecture changes if they find some issues. In one of the weekly meet, Soomin asked me to print an object, while we were in debug mode triggered by a breakpoint. I started writing print statement, he then showed me how we could just print object using the console and my mind just went 🤯. After which I have used that same command countless times and it is fair to say that it completely changed how I debug code.

This has been one of the most influential summer of my entire life as a developer. I learnt how to debug better, how to navigate complex and huge code base, how to learn new concepts better and more. I will continue to work towards completing my proposal after the final evaluation. Although the communication between the mentors and mentee could've been better and feedback loop on my work could've been decreased, increasing my efficiency to write code. But I am not complaining, I will always be grateful to get this opportunity. If nothing, this experience has shaped me as a better, more confident developer with less feeling of being an imposter in tech space.

From the bottom of my heart, to all my mentors Soomin, Edgar and Felix; org admins and VideoLAN, Thank You. And a special mention to Google for creating such an influential program to so much of us, student developers.