supabase-py icon indicating copy to clipboard operation
supabase-py copied to clipboard

Cannot get past this empty error

Open heymarkreeves opened this issue 9 months ago • 0 comments

Bug report

Describe the bug

Trying to execute a simple select query using Python 3.12 or 3.9. I cannot get past this error.

To Reproduce

Python 3.12.3 (main, Apr  9 2024, 08:09:14) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from supabase import create_client, Client
>>> from supabase.lib.client_options import ClientOptions
>>> url: str = "https://svyjpvnhftybdowglgmt.supabase.co/rest/v1/iot"
>>> key: str = "OMITTED"
>>> client_options = ClientOptions(postgrest_client_timeout=999999, schema="public")
>>> supabase: Client = create_client(url, key, client_options)
>>> print(supabase.table("iot").select("id").execute())
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/markreeves/.local/share/virtualenvs/vercel-tidbyt-35n3k3fp/lib/python3.12/site-packages/postgrest/_sync/request_builder.py", line 78, in execute
    raise APIError(r.json())
postgrest.exceptions.APIError: {}
>>> print(supabase)
<supabase._sync.client.SyncClient object at 0x1043c5a30>
>>> print (supabase.table("iot").select("id"))
<postgrest._sync.request_builder.SyncSelectRequestBuilder object at 0x1063f7fe0>

I've tried using postgrest directly too, receive the same error. Same happens with select("*").

Expected behavior

It works in RapidAPI or using requests to simply fetch my project URL, so it's not a permissions issue. I expect to not get an error using the documented methods.

System information

  • OS: macOS
  • Version of supabase-py: 2.4.5

heymarkreeves avatar May 05 '24 22:05 heymarkreeves