PublicLab: Mapknitter Export Module and Spectral Workbench upgrades

Hi guys, I’m Alax from Brazil.

I got accepted to work once again (yes, this is my second GSOC) with the PublicLab folks, my plan is keeping up the good from last year. Last year a lot was achieved in the PL organization, I intend to do even better this year.

Those few days that passed since GSOC results have been filled with work already. I’m very happy to have the chance to work with the PublicLab team once again. I have high expectations on this project since it has been going so nice already so far. This week I have done some planning by opening issues at the Spectral Workbench repository. Since my mentors and I have already established a communication channel (Gitter), I got to get practical these last couple of days and already did some coding. I have been preparing myself for this project for a long time, so I got to previously make several contributions that would make my job easier or at least less painful.

Below I’ll list some useful links regarding my work, and future plans:

  • Report of my work accomplished last year
  • What I want to accomplish this year

What I have already done this past month:

  • Updated Mapknitter’s Rails 6 pull request
  • Opened several initial issues at Spectral Workbench
  • Upgraded Ruby, Node and Rails version at Spectral Workbench (under review)
  • Upgraded Travis CI and Docker integration at Mapknitter-Exporter
  • Upgraded Travis CI and Docker integration at Mapknitter-Exporter-Sinatra

Community Bonding - Week 2

This week I got to do some planning and also chatting with the folks at PublicLab. I have talked to Ruturaj Mohite and we have succesfully included the SimpleCov test coverage tool in the Rails upgrade at the Spectral Workbench repository:

I have also participated in the community’s weekly bonding, where everyone in the community gets a chance to chat and report their accomplishments of the week:

I’m also awaiting review on some PRs, such as:

My plans on the upcoming week is to create a detailed Planning Issue, as my mentor @jywarren has requested, for both Spectral and Mapknitter Exporter projects.


Community Bonding - Week 3

This week I got to finish my planning issue and published it, I think it is very complete :partying_face:, but also very simple and with well defined tasks, it is all available at:

I have also opened a PR including the Codecov and Simplecov at the main Spectral Workbench branch, here:

This was a nice feature since it drives the PL org to a more standardized - thus friendly - ecosystem of projects. I got to collaborate with PL’s SysAdmin too :smiling_face_with_three_hearts: he’s given me a nice help at the PRs I was struggling with, which were:

He’s given me some feedback which I’m already going through.
My plans for the upcoming week is to work on the PRs mentioned above and start working on the test coverage upgrade for Spectral Workbench.


Community Bonding - Week 4

This past week I had a few personal problems, so I couldn’t get to be very productive, I had a discussion on next steps with my mentor at:

And I also had the help of my friend Ruturaj Mohite(@gr455) on upgrading the test coverage of the Spectral repository:

This next week I’ll focus on keep upgrading the test coverage and set up some system tests


Coding Phase - Week 5

This week I have gotten to increase Spectral Workbench’s test coverage here:

I have also gotten a reply from our sysadmin at:

He’s has given me the directions I needed and now I think the PR is ready to be merged. Also I have gotten to work on the Mapknitter repository here: Here I have setup a Dockerfile for production so we can properly run MK both in development and production environments.


Coding Phase - Week 6

This week I have set finished\ multijobs builds PR at Mapknitter-Export-Sinatra with the help of PL’s sysadmin here:

Still need someone to merge it though.

I have also done a HUGE refactoring at Mapknitter-Export-Sinatra codebase, in a few words, I have started modularizing the entire code structure. The benefits that this PR brought are that we now are avoiding potentially-confusing scoping problems, reduce code duplication(by using lambdas) e some other minor advantages that makes the difference as we scalate the project size. All of this work can be found here:

I have set Rubocop at Mapknitter Exporter Sinatra too so that we can maintain the standard set in other PL repositores(via: Mapknitter and Plots2). Also available here:

I have also opened a PR that changes our base docker image to Ruby’s official:

My PR that increases the test coverage at Spectral Workbench has been merged recently too:


Coding Phase - Week 7

This week I have been struggling on getting the Rails 4 PR merged in the production branch. I have gotten view access to the production logs, but now I need access to the script files that ships Spectral Workbench.

I have been also working in the Rails 5 upgrade in parallel while we can’t solve the production issue.

This has been a busy week for me at college, so I could accomplish much of my plans for this week, I still intend to keep moving forward with the Rails 5 upgrade and also setup Rubocop for the Exporter gem.

One nice achievement is that has finally been merged!!


Coding Phase - Week 8

This past week I have gotten to be able to run in production with the guidance of our sysadmin. I have also gotten to work with Ruturaj Mohite, one of the community members, in order to increase our test coverage, results are here

I have got to work a lot with our sysadmin, we have set and merged it. I have also included Rubocop and fixed SEVERAL offenses at the Exporter gem here And I have a done a lot of progress at the Rails 5 upgrade PR, here


Coding Phase - Week 9

This has been a very nice week, finally have gotten merged, with it I have fixed the Jenkins workflow and generated a fresh schema - the old was was preventing spectra to be saved.

In the Exporter Gem repository, we have also got the merge Which is part of the effort in standardizing the Public Lab codebase.

Also got to help our sysadmin by fixing Plots2 repository startup issue, the problem is described here and my fix is available here It has already been merged :slight_smile:


Coding Phase - Week 10

This week I have just been working on Rails 5 on Spectral Workbench repository, I decided to fix the failing tests before I get to work with Bower~>Yarn migration. This will be a very important update to Spectral, I already have gotten to increase the test coverage on around 80%.

We now using strong params practice from Rails, using newer Ruby and Rails syntax, using proper finders and much more.


Coding Phase - Week 11

This week I successfully got to fix all remaining tests at the Rails 5 PR and also got to include Yarn in favor of Bower (which is deprecated). So I got to finish everything I have planned.

By fixing the tests I have also gotten to do some syntax upgrades and improved the Spectral Workbench codebase error treatment. For the upcoming week I’d like to fix the eventual error that will pop up on Rails 5 and the Yarn upgrade PRs. Also I’d like to work on some more code modularizing for the Exporter Sinatra repository.


Coding Phase - Week 12

This week I got to completely remove Bower in favor of Yarn and added it to the asset pipeline in Spectral Workbench at

Also I have gotten the help of my friend Ruturaj to remove the usage of dynamic routes (which is a security concern) and manually write down every needed route. This is a very important step for the upgrade. For now I have been waiting for the sysadmin to fix a potential Nginx bug, so I can test Rails 5 on production, since I do not have access to it. But locally Spectral on Rails 5 works perfectly.


Coding Phase - Week 13

This week I got to successfully get the Rails 5 upgrade in production. Completely removed bower and its related deprecated files and completely setup Yarn, for javascript dependencies management.

In addition to that I have also gotten the help of my friend Ruturaj Mohite, who’s part of the Public Lab community, which helped me removing the dynamic routes out of Spectral Workbench. That was a very important feature because dynamic routing is a big security concern. Since latest Rails doesn’t allow abstract(dynamic) routing anymore, we’ve made Spectral less sensitive to security breaches, such as SQL injection.


Coding Phase - Week 14

I have been missing a little this past week. Unfortunately because a close friend of mine died in a motorcycle accident and my family and I have been taking care and supporting the loved ones. Hopefully God will bless them with some comfort in these hard times. This upcoming I’ll focus now on implementing the system tests on Spectral Workbench and implement GitPod on the Exporter Sinatra repo.
I’d also like to do some refactoring on the Exporter sinatra repo.


Coding Phase - Week 15

This week I have return my college activities so I didn’t produce as much as I wanted, but since I had my work ahead of schedule it’s not a matter of concern.

Anyways, I have focused on fixing the offenses pointed by Rubocop at:

Also I have set the system tests environment and implemented a couple of tests for validation at:

And also have gotten the help of my friend Ruturaj to identify and fix a bug that was causing the sets’ comments to not delete and also spectrums title/notes wouldn’t update - this has been fixed here:


Coding Phase - Week 16

This week I have done a lot of stuff. Finished including Rubocop configs and fixed a lot of offenses at:

I have also configured GitPod for both Spectral Workbench and Exporter Sinatra cli. Both available at:

And opened a pull request deprecating dynamic routing and fixing tons of other bugs at:


Final Evaluation

This week I have completed my GSoC report, which is available on PublicLab and on Medium.

It has been a great journey and I’ll be happy to present my work to the community on September 14th.


This topic was automatically closed after 61 days. New replies are no longer allowed.