Hackathon #2 part 4
Looking Back When Your Brain Feels under attack
Lets just say I don’t feel like sharing anymore because I am hella lost. This is the zone in which I have learned so much information and am stuck with so many bugs and not rested enough that I can’t reason out loud anymore. All I have left is muscle memory and pulling from that to rip our all the code I worked on an start from scratch.
This is the point of finding a break through I know it because in all my other hackathons recorded elsewhere this is the point where my notes dwindle and somehow everything magically works! I never know what it it that does the trick but I get over the hump fumbling in the dark.
The step I missed
npx @ai-sdk/codemod upgrade
Choosing to use pnpm
pnpm install
pnpm run dev —> work your way through the breaking changes
Setup local .env for localhost
Use the Vercel CLI
The Vercel CLI allows you to interact with your project's environment variables programmatically.
Install Vercel CLI:
npm install -g vercel
Login to Vercel:
vercel login
List Environment Variables: To see environment variables for your project:
vercel env ls
Export Variables: While there’s no direct command to export as a
.env
file, you can manually write them by redirecting the output to a file:vercel env ls > .env
Then format the file manually to look like:
VARIABLE_NAME=value
Two Days Later…
My build process failed due to multiple issues that need to be addressed systematically by going through them step by step:
After two days of attempted rest I found the mental capacity to continue walking through the errors and found the main issue to be needing to escape my apostrophes which I already knew I needed to do and suss out why the system wasn’t picking up my POSTGRES URL. Turns out the out of the box path is incorrect. I knew it as soon as I found this line of code.
config({ path: '.env.local', });
As you can see the true work of a developer / programmer / engineer is to suss out issues and problem solve for them we simply have to have patience and mental clarity to do so.
After this I ran
pnpm run db:migrate
and pushed my changes
I ran a local pnpm run build to check for additional errors and warnings and stepped through additional cod migrations that were straight forward.