haarismian
WWasp-lang
•Created by haarismian on 9/16/2024 in #đŸ™‹questions
How do I fix this db error
how do i fix this error
[ Server!] error: database "OpenSaaS-cd8dfa8fd6" does not exist
[ Server!] at /Users/haarismian/Development/Wisement/wisement/app/node_modules/pg-pool/index.js:45:11
[ Server!] at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
x.js:103:5)
[ Server!] at startPgBoss (/Users/haarismian/Development/Wisement/wisement/app/.wasp/out/sdk/wasp/server/jobs/core/pgBoss/pgBoss.ts:63:5)
[ Server!] at startServer (/Users/haarismian/Development/Wisement/wisement/app/.wasp/out/server/src/server.ts:14:3) {
[ Server!] length: 105,
[ Server!] severity: 'FATAL',
[ Server!] code: '3D000',
[ Server!] detail: undefined,
[ Server!] hint: undefined,
[ Server!] position: undefined,
[ Server!] internalPosition: undefined,
[ Server!] internalQuery: undefined,
[ Server!] where: undefined,
[ Server!] schema: undefined,
[ Server!] table: undefined,
[ Server!] column: undefined,
[ Server!] dataType: undefined,
[ Server!] constraint: undefined,
[ Server!] file: 'postinit.c',
[ Server!] line: '1019',
[ Server!] routine: 'InitPostgres'
[ Server!] }
[ Server ] Server listening on port 3001
[ Server!] node:internal/process/promises:289
[ Server!] triggerUncaughtException(err, true /* fromPromise */);
[ Server!] ^
[ Server!]
[ Server!] [UnhandledPromiseRejection: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason "#<PgBoss>".] {
[ Server!] code: 'ERR_UNHANDLED_REJECTION'
[ Server!] }
5 replies
WWasp-lang
•Created by haarismian on 9/2/2024 in #đŸ™‹questions
If I want to create a second project, what considerations do I need to make?
If I want to create a second project, what considerations do I need to make? I want to create a second local project, but I am worried if I run wasp db start for the first time it might mess with my db for my original project that i started with the saas template
7 replies
WWasp-lang
•Created by haarismian on 8/9/2024 in #đŸ™‹questions
How do I change the text that appears when I share my URL
5 replies
WWasp-lang
•Created by haarismian on 8/8/2024 in #đŸ™‹questions
database subscriptiontier and subscriptionstatus do not get updated on stripe completion
database subscriptiontier and subscriptionstatus do not get updated on stripe completion
13 replies
WWasp-lang
•Created by haarismian on 8/6/2024 in #đŸ™‹questions
What is the best place to initialize tracking on the backend
What is the best place to initialize tracking on the backend
12 replies
WWasp-lang
•Created by haarismian on 8/6/2024 in #đŸ™‹questions
How do I access the user's email when they signed up with google
How do I access the user's email when they signed up with google, the email column is null when they signed up with google
12 replies
WWasp-lang
•Created by haarismian on 8/6/2024 in #đŸ™‹questions
Unable to tunnel to production db
I set my databse_URL to my production db following the instructions here: https://github.com/wasp-lang/wasp/issues/1464 and when running wasb db studio I get this error, "The database needs to be running in order to execute this command. You can easily start a managed dev database with
wasp start db
."16 replies
WWasp-lang
•Created by haarismian on 7/30/2024 in #đŸ™‹questions
if I don't use "www." then my app doesn't show
Hey folks (@kapa.ai in particular lol),
if I use "www." to go to my app. then my app doesn't show up and I get the squarespace under construction page, but if I leave www. out then my app runs just fine. Any ideas what I could do to fix this?
18 replies
WWasp-lang
•Created by haarismian on 7/28/2024 in #đŸ™‹questions
How to edit google oauth credits
I want to be able to edit the number of credits an account has, both locally and in prod, for google accounts, how can I do that. I know for normal email accounts I can use wasp db studio and edit
18 replies
WWasp-lang
•Created by haarismian on 7/25/2024 in #đŸ™‹questions
When I made a custom api, I added user as an entity, but in the context it is empty
This is my main.wasp
api socialPostMakerText {
httpRoute: (POST, "/api/social-post-maker-text"),
fn: import { getText } from "@src/server/socialMediaMakerPostText.js",
entities: [User]
}
This is when I console log the context
context {
[ Server ] user: undefined,
[ Server ] entities: {
[ Server ] User: {
[ Server ] findUnique: [Function (anonymous)],
[ Server ] findUniqueOrThrow: [Function (anonymous)],
[ Server ] findFirst: [Function (anonymous)],
[ Server ] findFirstOrThrow: [Function (anonymous)],
[ Server ] findMany: [Function (anonymous)],
[ Server ] create: [Function (anonymous)],
[ Server ] createMany: [Function (anonymous)],
[ Server ] update: [Function (anonymous)],
[ Server ] updateMany: [Function (anonymous)],
[ Server ] upsert: [Function (anonymous)],
[ Server ] delete: [Function (anonymous)],
[ Server ] deleteMany: [Function (anonymous)],
[ Server ] groupBy: [Function (anonymous)],
[ Server ] count: [Function (anonymous)],
[ Server ] aggregate: [Function (anonymous)],
[ Server ] findRaw: [Function (anonymous)],
[ Server ] aggregateRaw: [Function (anonymous)],
[ Server ] name: 'User'
[ Server ] }
22 replies
WWasp-lang
•Created by haarismian on 7/15/2024 in #đŸ™‹questions
Sendgrid is not sending sign up emails
I have set up sendgrid in my app. The sender authentication and domain authentication is verified. Both the email fields in main.wasp are populated correctly under auth and email sender. However when I am testing creating a new account locally, I get a 200 from the app terminal for POST /auth/email/signup 200 but I do not see any api request in sendgrid, and the sign up account doesnt get an email.
11 replies
WWasp-lang
•Created by haarismian on 7/10/2024 in #đŸ™‹questions
can I implement another analytics tool like posthog?
I want to use posthog for product analytics, can I use the npm package and where should i initialize posthog. both on the frtonend and backend
10 replies
WWasp-lang
•Created by haarismian on 7/6/2024 in #đŸ™‹questions
fly.io frontend keeps crashing
hey folks, my fly.io deployed app keeps crashing, not sure why, I don't even know how to begin investigating why it keeps crashing, it says its suspended in the fly.io dashboard and these are some recent logs
7 replies
WWasp-lang
•Created by haarismian on 6/26/2024 in #đŸ™‹questions
I am getting a 404 with a custom api when using a parameter
this is my wasp api
api getPexels {
httpRoute: (GET, "/api/get-pexels/:query"),
fn: import { getPexels } from "@src/server/pexels.js",
}
this is my api call
const res = await api.get(
and this is my backend function export const getPexels: GetPexels<{ query: string }> = async (req, res, context) => { console.log('pexels called');
/api/get-pexels?query=${selectedCity}
);
and this is my backend function export const getPexels: GetPexels<{ query: string }> = async (req, res, context) => { console.log('pexels called');
5 replies
WWasp-lang
•Created by haarismian on 6/25/2024 in #đŸ™‹questions
How can I create an onboarding flow where forms the user fills are saved to their account
How can I create an onboarding flow where I ask users questions and save their answers in the database, for use later? For example I ask them their favorite colour and I want to show it to them alter.
9 replies
WWasp-lang
•Created by haarismian on 6/25/2024 in #đŸ™‹questions
should an external api call to get photos be a query or an action or custom api
should an external api call for a get request to see photos be a query or an action or custom api
15 replies
WWasp-lang
•Created by haarismian on 6/23/2024 in #đŸ™‹questions
deploying to custom URL does not work consistently
8 replies
WWasp-lang
•Created by haarismian on 6/18/2024 in #đŸ™‹questions
How do I prevent the api call from being run every time sate is changed, and only run on button pres
I would love some help on how I can make sure the api call is only run when the button is pressed and not every time state changes. I want to pass the state variables to the
usetextstream
function so that I can stream text from chatgpt to the frontend. But whenever any state changes the usetextstream function is run, this is creating a user experience where anything the user does makes an api call and starts streaming text. I would love if it only ran when the user clicks the generate social media post button.4 replies
WWasp-lang
•Created by haarismian on 6/8/2024 in #đŸ™‹questions
How can I implement server sent events
How can I implement server sent events in the actions.ts? I understand that all the backend functions are added to actions.ts, but I would like to add a server sent event function to actions.ts
Thanks for the help!
11 replies
WWasp-lang
•Created by haarismian on 6/8/2024 in #đŸ™‹questions
How do I implement text streaming from the openai api
How do I implement text streaming from the openai api
18 replies