Reviewery: Music rating iOS application, a year later

Vadym Markov
hyperoslo

--

This is the second part in the Reviewery series. Check out the first part Reviewery: Music rating iOS application built in React Native before you start reading this one.

Believe it or not, but we have stepped in 2018. And for me, among other things, it brings a new round of monthly playlists, with carefully selected songs I’m going to vote for during this year. It’s time for Reviewery v2 to help us become even better music critics 🤓.

Reviewery application worked pretty well and served its purpose last year. Me and my wife have successfully finished reviewing songs, and as an award for our scrupulousness and patience we got back our own personal “Top 2017” playlist, with 100 tracks sorted by rating. What else could we dream of? It’s been a lot of fun to use this app, monitor results and then, during Christmas holidays, listen to the best songs chosen by us, not by machine learning algorithms that think they know all about our music tastes and preferences (even though it’s partially true). If you feel adventurous you can find this playlist on Spotify 🎵.

So what’s the plan for 2018? Well, I came into conclusion that it’s not so easy to get accurate results when songs are rated from 0 to 10 stars. There is no better alternative than sorting the songs alphabetically when they have the same score. That’s why this time I’ve decided to increase max amount of stars from 10 to 12. Will see how it goes, but I hope it will make end results more diverse.

Increasing the rating is just a small change in the app, but let’s not forget that the last time I built the project was one year ago. Even though I made a conscious decision to not update React Native there still could be potential issues to get the project up and running on new version of macOS and Xcode.

The first thing I did was:

react-native run-ios --simulator="iPhone X"

As I expected, it didn’t work. Instead, it just hang in the terminal indefinitely. Fortunately I found a fix for this problem and after running

rm -rf /usr/local/var/run/watchman/<USER>-state

the app was successfully installed on my iOS simulator 🎉.

Then I couldn’t help myself and made a few changes to colour scheme of the app, which was super easy with hot reloading:

But the most annoying problem was waiting for me in the end. When I was ready to install the app on my phone Xcode surprised me with the following error message:

A valid provisioning profile for this executable was not found.

I spent a lot of time trying to figure out the reason, and eventually it turned out that the problem was with the signing team not being set for the test target. I checked my main target multiple times, but I didn’t expect it could have something to do with tests 😅. There were no Swift/Objective tests anyway, so I ended up removing this target and the issue was solved.

Last but not least, when I finally ran the app on my phone I saw this under runtime issues:

As you might know, it’s due to Main Thread Checker tool in Xcode 9, which detects invalid use of UIKit from a background thread. I would assume it’s fixed in newer versions of React Native, but it’s not a show-stopper for my experimental hobby project at the moment. I was happy enough to get it installed and ready to use 😎.

What do I think? Well, it wasn’t that bad after all. I suspect it would take more time if I decided to update React Native and all necessary JavaScript dependencies. Thanks, but no thanks. Maybe next time.

That’s all, folks. Happy coding! Explore, learn and create. 🎶

--

--

Vadym Markov
hyperoslo

iOS Developer at @hyperoslo, independent artist at @hypnocrates. Believe that delightful code and beautiful music will save the world.