Comments (8)
Maybe it's a linking issue? Running pnpm db:gen
gives following error:
❯ pnpm db:gen --verbose
> test-sst-ion@ db:gen /Users/frixaco/personal/test-sst-ion
> AWS_PROFILE=default sst shell drizzle-kit generate:pg "--verbose"
time=2024-03-24T19:41:43.422+05:00 level=INFO msg="checking for bun" path="/Users/frixaco/Library/Application Support/sst/bin/bun"
time=2024-03-24T19:41:43.422+05:00 level=INFO msg="initializing project" version=0.0.197
time=2024-03-24T19:41:43.423+05:00 level=INFO msg="esbuild building"
time=2024-03-24T19:41:43.425+05:00 level=INFO msg="esbuild built" outfile=/Users/frixaco/personal/test-sst-ion/.sst/eval/eval-1711291303423.mjs
time=2024-03-24T19:41:43.425+05:00 level=INFO msg="evaluating config"
time=2024-03-24T19:41:43.451+05:00 level=INFO msg="config evaluated"
time=2024-03-24T19:41:43.451+05:00 level=INFO msg="checking platform"
time=2024-03-24T19:41:43.452+05:00 level=INFO msg="credentials found"
time=2024-03-24T19:41:43.452+05:00 level=INFO msg="fetching bootstrap"
time=2024-03-24T19:41:45.026+05:00 level=INFO msg="found existing bootstrap" data="{\"version\":1,\"asset\":\"sst-asset-runmwdcehbtz\",\"state\":\"sst-state-runmwdcehbtz\"}"
time=2024-03-24T19:41:45.027+05:00 level=INFO msg="loaded config" app=test-sst-ion stage=frixaco
time=2024-03-24T19:41:45.027+05:00 level=INFO msg="INFO getting data key=link app=test-sst-ion stage=frixaco"
drizzle-kit: v0.20.14
drizzle-orm: v0.30.4
No config path provided, using default 'drizzle.config.ts'
Reading config file '/Users/frixaco/personal/test-sst-ion/drizzle.config.ts'
Error: "TestSSTDatabase" is not linked
at Object.get (/Users/frixaco/personal/test-sst-ion/node_modules/.pnpm/[email protected]/node_modules/sst/dist/resource.js:15:15)
at Object.<anonymous> (/Users/frixaco/personal/test-sst-ion/database.ts:19:22)
at Module._compile (node:internal/modules/cjs/loader:1376:14)
at Module._compile (/Users/frixaco/personal/test-sst-ion/node_modules/.pnpm/[email protected]/node_modules/drizzle-kit/bin.cjs:8644:30)
at Module._extensions..js (node:internal/modules/cjs/loader:1435:10)
at Object.newLoader [as .ts] (/Users/frixaco/personal/test-sst-ion/node_modules/.pnpm/[email protected]/node_modules/drizzle-kit/bin.cjs:8648:13)
at Module.load (node:internal/modules/cjs/loader:1207:32)
at Module._load (node:internal/modules/cjs/loader:1023:12)
at Module.require (node:internal/modules/cjs/loader:1235:19)
at require (node:internal/modules/helpers:176:18)
from ion.
@frixaco what's the name of the app defined in sst.config.ts
?
from ion.
@fwang Thanks for a response. I'm not sure I understand what do you mean by "app". If you are asking about whether it's a Next.js/Remix app, then no. It's just a Function linked to a database (wanted to make bundling migration files with lambda handler work in a Function).
Let me know if you need more details.
from ion.
we mean what's at the top of your sst.config.ts, the part you cut out
when you don't specify a default database name to the postgres component we use the app name as the database name, seems like yours is not valid
from ion.
@thdxr Thanks for clarifying.
It is test-sst-ion
🤦♂️ , it is using the name of root project directory. Sorry, that's my bad for being a bit careless, didn't realize that.
Maybe Ion can auto "fix" the app name when running sst init
? (I'm down to implement it, though I haven't looked at the source code yet)
from ion.
oh can database names not have hyphens? @fwang should we strip them?
from ion.
Gonna assign to Frank
from ion.
Fixed in 0.0.226
Hyphens will be replaced by underscores, which are allowed for Postgres database names.
from ion.
Related Issues (20)
- Redirects are not supported when DNS is disabled
- Provisioned concurrency for lambda
- Docs: component versioning
- Expo cant bundle with sst HOT 2
- Transform errors | Nuxt | Type 'void' is not assignable to type 'undefined'. HOT 1
- API routes in NextJS don't return any data
- SST state and assets S3 buckets fail AWS Security hub
- Remix/SsrSite: allow cloudFrontFunctions custom injections for serverCfFunction & staticCfFunction
- Default Lambda policies not being managed on changes
- Can't create AWS Lambda router: "The parameter origin name must be a domain name."
- Could not open a new TTY when running sst install
- middleware "error": Routing failed. TypeError: globalThis.__import_unsupported is not a function
- Remix Vite Config Resolution Broken in Monorepos HOT 1
- either 'content' (presen t: true) or 'data' (present: false) must be provided - cloudflare HOT 3
- Unable to get environment variables injected into NextJS Site Deployment
- Menu button on website no longer works for mobile HOT 1
- Outdated Cloudflare DNS Record Args
- Support deployment with lambda@edge
- Specific version installation is not working for 3.0
- Install script redownloads SST on every execution
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ion.