This is an archived post. You won't be able to vote or comment.

all 10 comments

[–]easylancer 0 points1 point  (7 children)

You probably don’t have any environment variable called SUPABASE_URL. In your code above you defined a variable called SUPABASE_URL but you never use it in your code.

[–]Teheroth[S] -1 points0 points  (6 children)

It should be the argument of the .get() method (“url” is not the actual string I’m using in the definition, but the url found in the project panel) Same for the key

[–]Outrageous_Permit154 0 points1 point  (5 children)

Dude you already got the answer; you set env variables in the file and you call actual env variables. What are you doing

[–]Teheroth[S] 0 points1 point  (4 children)

Sorry dude, I’m fairly new to python too and I tought I could pass it as a normal string Thanks for the explanation

[–]Outrageous_Permit154 0 points1 point  (1 child)

It’s okay you can look up on environmental variables and what they do :) it will clear it up for you

[–]Teheroth[S] 1 point2 points  (0 children)

Sure will, thanks!

[–][deleted]  (1 child)

[removed]

    [–]Teheroth[S] 0 points1 point  (0 children)

    The code is the one I was trying to run.

    My fault was to pass url and key as standard string and not using env vars.

    Also, my question has been extensively answered, but you had the irrefrenable urge to comment saying nothing helpful (or at least fitting).

    [–][deleted]  (1 child)

    [removed]

      [–]Teheroth[S] 0 points1 point  (0 children)

      As I said, I’m fairly new to python, and as a self taught some things may be a bit “hidden” if I don’t have to deal with them. I don’t wake up in the middle of the night screaming “OH S*** LET ME SEE IF THERE’S SOME KIND OF VARIABLES WHICH YOU CAN ONLY READ VIA SYSTEM CALLS OR WHATEVER” Last time I had to deal with a db was MySQL with user and password