fetch failed with app directory
Hey guys, I'm kind of stuck with drizzle at my first try using the app directory.
I have defined the following db query in my page.tsx:
But somehow I always get the error
Full stack trace:
Node version:
NextJS:
I have defined the following db query in my page.tsx:
But somehow I always get the error
- error TypeError: fetch failedFull stack trace:
Node version:
v16.13.0NextJS:
13.4.7
Solution
Yes!
I found the issue. It was, that somehow the creator of my repository, that I used as template, used
I found the issue. It was, that somehow the creator of my repository, that I used as template, used
@planetscale/database, but I was not using planetscale for my dev environment and so it did not work. This now also makes sense with the port 443, which was actually the tried connection to the database url (which was 127.0.0.1 at this moment) and so it did not find any database, because there was none. Now I've changed to drizzle-orm/mysql2 and I will use @planetscale/database in production