2023-12-29: Straight into the fire
Tags: devjournal
Published: 2023-12-29 23:20:53

This week's been pretty nuts.

As it stands, the code and cloud infrastructure of my new company are a big pile of spaghetti. I am looking to straighten out everything in the coming weeks, but it's going to be a large, coordinated effort. Unfortunately, due to nature of being a pre-seed startup, we don't have enough funds at the moment to hire a whole team of developers, so I'm on my own at the moment, still working with the contracted team on the other side of the Earth until we do get that funding.

However, it's definitely been an even more accelerated learning experienced from even my previous company, which was already accelerated. I hope to learn more as time permits, especially going into this new year.

To detail some of my technical challenges this week, let's start with Tuesday (Monday was Christmas for the West, so we were off).

As mentioned last time, our primary concern at the moment is getting a Terraform script set up so that we can use it to easily spin up environments in the future. It's been a major pain in the rear. Friday afternoon we'd decided to hire a contractor to try to fix up the Terraformer-generated code, and we had to work on the weekend between each other to try to get that all cleaned up. I had granted him credentials and all that through GCP's IAM policies.

However, once I received this cleaned-up Terraform code, our other team said that it was completely disorganized, so one of them just redid it from scratch. Which is fine, but it sucks that the weekend work was mostly a waste.

Since I was more free to do other stuff once he took over that, I started my mad descent into the codebase and fixing up and bad practices that I came across. The code is almost entirely undocumented, so I have been using Copilot Chat to explain it all for me, which has been very helpful.

After that, I went over the CSO's additions and edits to some of the prompt engineering from Friday and gave him some tips in that regard. There was also an issue with one of our database tables somehow getting deleted a second time, so I had to deal with restoring that and losing 16+ new registrations. Our strategy was to just let people send support tickets as needed since we don't know who exactly was affected. However, to remedy this, I created a little script to re-add people's trial subscriptions in case they need it.

As I'm receiving errors from our Sentry, I am fixing them as quickly as I can without messing up anything else. The code is not modularized very well, so touching it in one place will affect it elsewhere. It is definitely putting a hamper on my productivity. Speaking of which, yesterday was insane. I had noticed that the domain names were pointing to the wrong Cloud Run instances, so I changed it because I wanted the new onboarding experience to show up, but apparently this threw the entire system into chaos. For some bizarre reason, this caused the environment variables to no longer work on the frontend, so nothing was actually loading on the website, and the login and register weren't working either. The backend server string was an environment variable. There was no rational approach to fixing this, so I just decided to replace the lines in the code to have hardcoded URLs for the time being until someone on the other team can figure out how that's even happening. 

Today, Friday, I redid our kanban board inside of Notion instead of Trello which is what was previously being used, since I guess the CEO wants it to be all centralized there. I had meant to do it Thursday, but, y'know, fireman watch duty the entire day. We also all wrote little bios about ourselves to get to know each other better and for future hires. 

I spent most of the day organizing the board, until the CEO had notified me once again that the same issue was cropping up, so I check our code and Sentry and see that someone from the other team pushed a change to "fix" the environment variable issue, but it didn't actually work. So I reverted it back to hardcoded values and told him to only do this stuff on staging until he's 100% certain that it works.

Either way, I guess that's all for now. Here's to an end of 2023, see you guys next year. Cheers.