palpatine and rwar


Partnering up

Samina and I have joined a lot of Hackathon’s in the past and ended up working at Seneca Innovation together over the summer. I find our work spirit to be similar and we both have a lot of passion for what we do. So we have decided to contribute to each other’s Static Site Generator (SSG) project.

Explore the unknown – rwar

Reading someone else’s code is something I don’t really enjoy doing. Nonetheless, it’s a vital skill to have in the software development field. I find it hard to understand what is going on and spend most of my time in debugging, just to see how they work. However Samina’s code had clear implementation and as we both had some prior experience in Python at work. Due to having that background it was not too hard for me to understand what is going on.

Review of the palpatine

I am always pleased if somebody takes their time to review and test my code and then provide specific feedback that I can work on.

Issues I have filed for my partner Samina

  • Inconsistency of titles in the terminal – Issue # 1
    • I have noticed that the titles of the textfiles output in the terminal were not consistent. For example, some were uppercase and some were lowercase. This issue wasn’t a big deal as they were only in terminal not in the html. However, I thought it would be a good idea to make them consistent for such a great real-world tool since its usage and visibility is beyond the classroom.
  • Readability of the static site – Issue # 2
    • I have noticed that the generated static site was not easy on the eyes. She has written custom css to style it but in my opinion, in this scenerio, it would make more sense to use a classless framework. For example I have used Bahunya in my project palpatine. I also have used animate.css to add some fancy animations to the static site. So I have filed an issue to use a classless framework to make the static site more readable.
  • Documentation – Issue # 3
    • This issue again was not related to the code implementation but documentation of repo. I have noticed that the documentation was not very clear. Use of tables is a nice way to demonstrate all the flags available in the tool. I have filed an issue to add a table in the documentation to make it more readable.
  • Exception handling – Issue # 4
    • This issue is almost same as the issue I got filed for my ssg palpatine as well. Samina reached out to me to ask how I handled the raw data files other than text files such as .md files. My answer to that was - I am not :P. So we filed issues to each others repo to add exception handling for such files.
  • Logo – Issue # 5
    • Sam and I have similar file structure. However, the logo she had in the was within the repository. This behavior is not recommended as it is redundant and increases the size of the repository. I have filed an issue to use a image hosting service such as imgur to host the logo and use the link in the file.

Issues I got filed for my project

  • Error handling – Issue # 1
    • Currently, palpatine v1.0.0 only supports text files. However, if a user tries to use it with other file types such as markdown files, no explanatory error is thrown. I suppose such feature is necessary for everybody in OSD600 as the instructions for lab1 is not stating we need to support other formats. Although, I think we will work on such feature in further releases.
  • Documentation for a variety of OS – Issue # 2
    • Currently, palpatine v1.0.0 is only developed and tested in a macOS environment with Clang++. Thus, I was not able to provide detailed instructions for windows. Good news! palpatine is a CMake project, meaning that it supports cross-platform build system and is compiler independent. With the same CMakeLists.txt file someone can easily create a Windows build (Visual Studio). However, I have not tested it yet, so if something fails feel free to comment below or file an issue in palpatine. I manage my tools with the Homebrew package manager in macOS. So if you follow the palpatine instructions in precisely you will be able to install it in macOS.
  • Indentation of HTML – Issue # 3
    • I have noticed that the generated HTML files are not indented. While, it makes no difference in the browser, I understand it is a good practice to have properly intended HTML files.
  • Modularity – Issue # 4
    • I tried to make the code modular as much as possible. However, in main.cpp I have used the argparse and termcolor along with the main function. As Sam, pointed out, it would be a good idea to move them to a separate file and import them in main.cpp.
  • Clarification of CMake – Issue # 5
    • As I mentioned above CMake is really powerful, open-source cross-platform build system. A good resource can be found in here or you can read through the file.

I still have 2 issues open – Issue # 2 and Issue # 4. I still am working on Issue#2 as it requires me to do some research and finally test it using VM. I will update the issue once I am done. Issue#4 is a minor issue and I will fix it in the next release. I have updated my code to address error handling for non-txt files using if-else statement. You can check it from this commit. I also added more documentation for CMake and fixed HTML indentation here commit

Leave a Reply

Your email address will not be published. Required fields are marked *

Previous Post

How to update WP User Billing and Shipping Meta via WP Rest API

Next Post

Best Way to Learn for Self-taught Android developer

Related Posts