A Separation of Concerns: My First Hackathon

James Ardery
5 min readMay 2, 2021

Over the past week I participated in the Nurture Hackathon that was put together by Cody Green and Flatiron. The theme was to build and app that focuses on nurturing difference.

  • Seek to understand. Assume positive intent. Question your assumptions. Take responsibility for your own growth and actions.
  • Notice who or what is missing. Actively seek out different opinions. Create space for other voices to be heard.

While this is a very broad topic I had recently thought of an app idea that actually fit the criteria. Enter YumYum Fresh the app designed to showcase seasonal local produce available to a user based on their current location and current date/time. As the group fleshed out the idea we landed on this mission statement.

Encouraging eating fresh, local, and sustainable produce is not only good for local communities and farmers, more importantly it’s good for the body, for the soul. Food is one of our most basic common, human unifiers. It’s how we nurture ourselves, it’s how we nurture others.

The project itself presented a variety of challenges but the first became apparent right away. This was the largest group I had ever worked with before and while I had “come up with the idea” fleshing it out into a full app and delegating roles was not something I had figured out. Our group consisted of 6 developers and to be quite honest a natural pairing of teams, skill sets, and interests formed entirely independent of me 💅🏽. I would like to claim that I had this planned out all along but that would be a lie.

Separation of Concerns:

UX / UI / Styling Team:

Frontend Team:

Backend Team:

I now fully appreciate why companies build teams in such a manner. The teams were able to accomplish so much more by focusing on their own narrow concerns. The end result is an app that is going to continue to grow from the hackathon and in my humble opinion was the best project presented that day 😉.

From a backend perspective Demetrio and I had 2 major hurdles.

  1. Developing a functional modal relationship
  2. Getting our hands on good data.

Neither were easy. The modals we settled on were State / Harvest / Produce.

The key to the functionality is that our harvest modal has an attribute of months which is an array for all the months determining the length of the harvest. The harvest would have a state_id and a produce_id it would belong_to. With this relationship would tackled the challenge locational climate because aNew York apple has a different growing season than an Oregon apple. BOOM!

Now getting the fetch cleaned up for our frontend team was another piece to this puzzle. It was ultimately solved by some custom serialization rending out this JSON example for all produce available in New York during the month of October.

There are more pieces of produce available in the New York in October but you can see the custom serialization in our fetch response with the only_associated_harvest. This custom serialization required methods that would need to return produce available only in the users state at the specific month in the year. Produce does not have a state attribute, only harvests do. So we needed lookup_id’s for both harvests and states to only render produce associated with New York. Then we built custom methods that could take a users current month and iterate through all of the New York harvests to see if there was a corresponding month match!

Now that our first backend challenge was complete we needed to then shift our focus towards where we could get this data. This hurdle was much much MUCH bigger than we could have ever guessed. We actually reached out to Cornell University to see if they had information we could potentially use. They were quick to respond and enthusiastic about our project but what quickly became apparent is that the database we were hoping to find did not exits anywhere online. Many people seem to have attempted this but either failed to maintain the project or would simply focus on a single state. Cornell is currently putting together a database for the state of New York. The United Stated Department of Agriculture has a few APIs available but none that provide produce information based on season and location.

So in short we simply built a very VERY small database, based on compiling lots of google research, to showcase the apps functionality and present at the hackathon. We are scheduled to meet with a large urban farm based out of NYC called Brooklyn Grange this week to discuss how we can get our hands on more reliable and current data. There are a few other local organizations that would be promising to partner with to get version 2 of YumYum Fresh off the ground. To recap in 2 weeks I have already worked on the largest team so far in my short life as a dev and it is quickly becoming apparent how many more people we will need to truly get this idea off the ground!

While I do plan to continue to grow my frontend and backend skills as a developer the current version of YumYum Fresh would not have been possible with out the immediate separation of concerns established by the awesome group at YumYum Fresh. Maintaining separation and focus while also keeping the team corralled around a common goal is the biggest hurdle ahead. I think the future is looking bright for YumYum Fresh and hopefully this little blog will act as a time capsule for the larger project on the horizon.

--

--

James Ardery

Budding Software Engineer trying to find the tie that binds 🤔