Bloxs
05/09/2023, 11:42 PMnicollegah
05/10/2023, 12:37 AMmatthieup
05/10/2023, 4:24 AMStiffJobs
05/10/2023, 4:43 AMActual Left Shark
05/10/2023, 4:57 AMvinciarts
05/10/2023, 5:40 AMMartin Piliar
05/10/2023, 6:02 AMDaJacy
05/10/2023, 9:14 AMdart
final res = await supabase
.from('exercises')
.upsert(data, onConflict: columnId)
.match({'id': data['id']}).lt(
columnLocalTimestamp, data[columnLocalTimestamp]);
I would appreciate help very much!indymaat
05/10/2023, 9:38 AM/new
-/tables
-/policies
-/constraints
--/primary keys
--/foreign keys
--/check
-/indexes
-/...
/latest
-/triggers
-/views
-/functions
-/...
/drop
-/tables
-/constraints
-/...
and so on...
Is there any way, or should all changes be done inside 1 migration script?Nico
05/10/2023, 9:54 AMyarn rw migrate dev
command (I'm using redwood), I keep getting error P4002 saying this :
The schema of the introspected database was inconsistent: Cross schema references are only allowed when the target schema is listed in the schemas property of your datasource. public.create_info
points to auth.users
in constraint create_info_id_fkey
. Please add auth
to your schemas
property and run this command again.
I was following this tuto : https://redwoodjs.com/docs/tutorial/chapter4/deployment
Do I need to add specific line in my schema.prisma ?bilals
05/10/2023, 9:58 AMsbp_0102...1920
. Try rerunning the command with --debug to troubleshoot the error.
I have tried dding quotes to my token, i also generated a new token, but nothing seems to work. What am i doing wrong?YashG
05/10/2023, 11:04 AMven
05/10/2023, 11:11 AMHi Ven,
You should not need a Logflare account, only a Google Cloud account.
Could you reference tne Analytics server self hosting docs here:
https://supabase.com/docs/reference/self-hosting-analytics/introduction#getting-started
Looks like the example config.toml is pointing to the Logflare docs by mistake, i'll get that fixed.
I hope they fix that toml file and inform us so that we can update our local instances safely.
https://cdn.discordapp.com/attachments/1105814365468364840/1105814365896196096/config.toml.png▾
Saad
05/10/2023, 11:34 AMhttps://cdn.discordapp.com/attachments/1105820155684073553/1105820155843465357/local_instance.png▾
https://cdn.discordapp.com/attachments/1105820155684073553/1105820156141248542/cloud_instance.png▾
lynq-paul
05/10/2023, 11:39 AMnateland
05/10/2023, 11:52 AMhttps://cdn.discordapp.com/attachments/1105824584609046659/1105824584990732318/Screenshot_2023-05-10_at_1.51.41_PM.png▾
kresimirgalic
05/10/2023, 12:17 PMSunTzu
05/10/2023, 1:27 PMTypeError: t is not a function
at Ke.exports (https://esm.sh/v120/axios@0.26.1/esnext/axios.mjs:3:5734)
at T.request (https://esm.sh/v120/axios@0.26.1/esnext/axios.mjs:3:9122)
at Function.request (https://esm.sh/v120/axios@0.26.1/esnext/axios.mjs:2:839)
at https://esm.sh/v120/openai@3.2.1/esnext/openai.mjs:2:3794
at https://esm.sh/v120/openai@3.2.1/esnext/openai.mjs:2:26914
at async n._fn (https://esm.sh/v120/p-retry@4.6.2/esnext/p-retry.mjs:2:1577)
any ideas?
Supabase CLI Version: 1.57.4
Code tried to be used below:
const chain = ConversationalRetrievalQAChain.fromLLM(
model,
supaStore.asRetriever(null, { chatbots: `%${body.bot}%` }),
{
qaTemplate: contextprompt,
returnSourceDocuments: true,
}
);
console.log("about to chain call");
const res = await chain.call({
question: body.user_message,
chat_history: [],
});
Hexxadon
05/10/2023, 1:51 PMpuffybatman
05/10/2023, 1:54 PMCREATE POLICY "allow everyone" ON "public"."tbl"
AS PERMISSIVE FOR INSERT
TO public
WITH CHECK (true)
About returns this error:
WSError (CompactDecodeError Invalid number of parts: Expected 3 parts; got 2)
jdom93
05/10/2023, 2:03 PMsupafloh
05/10/2023, 2:38 PMjs
const [data, error] = await supabase
.from('profiles')
.select(decrypt('sensitive_info'))
.eq('user', user.id)
If not, is there a way to do this in the edge function where I'm sending the value after the client fetches it?ven
05/10/2023, 3:01 PM2023-05-10 09:30:51 serving the request with /home/deno/functions/contact
2023-05-10 09:30:51 Error: channel closed
2023-05-10 09:30:51 at async Function.create (ext:sb_user_workers/user_workers.js:75:21)
2023-05-10 09:30:51 at async Server.<anonymous> (file:///home/deno/main/index.ts:94:24)
2023-05-10 09:30:51 at async Server.#respond (https://deno.land/std@0.182.0/http/server.ts:220:24)
and here is the contact me services class making the call
const supabaseClient = createClient(
Deno.env.get('SUPABASE_URL') ?? loadDotenv().SUP_SUPABASE_URL ?? '',
Deno.env.get('SUPABASE_ANON_KEY') ??
loadDotenv().SUP_SUPABASE_ANON_KEY ??
''
);
export class ContactMeService {
async getAllContacts(): Promise<ContactMeRecord[]> {
const { data, error } = await supabaseClient
.from('contact_me')
.select();
console.log('contact me data');
console.log(data);
if (error) {
throw new Error(`Failed to fetch contacts: ${error.message}`);
}
return data as unknown as ContactMeRecord[];
}
}
https://cdn.discordapp.com/attachments/1105872124679295047/1105872124918386809/contact_me_table.png▾
https://cdn.discordapp.com/attachments/1105872124679295047/1105872125316837427/unit_test_passes_but_with_empty.png▾
Kyborq
05/10/2023, 3:24 PMbombillazo
05/10/2023, 4:32 PMsupabase functions serve
command. I am getting the error:
sh
error: Module not found "file:///home/src/transform/item.transform.ts".
at file:///home/deno/functions/my-function/index.ts:5:29
I have this in my import map:
json
// import_map.json
{
"imports": {
"@utils/": "./../src/utils/",
}
}
And I am importing in the file like this:
js
// my-function/index.ts
import { item } from '@utils/transform/item.transform.ts';
Is there any way to import files relative to the edge function index?Phillip
05/10/2023, 4:43 PMbegin
update public.resource set reviewratingavg = (select CAST (AVG(rating) AS float8) from public.review where resource::text = new.resource::text) where resource::text = new.resource::text;
return new;
end;
goldyman
05/10/2023, 4:48 PMbody=eq.1234|body=eq.98756
yawn
05/10/2023, 4:57 PMbilals
05/10/2023, 4:59 PMAce
05/10/2023, 5:00 PM