Skip to content
This repository has been archived by the owner on Jul 14, 2023. It is now read-only.

Wrong output when checking if table exists #57

Open
Gorgoras opened this issue Jan 16, 2021 · 0 comments
Open

Wrong output when checking if table exists #57

Gorgoras opened this issue Jan 16, 2021 · 0 comments

Comments

@Gorgoras
Copy link

Description

When calling the exists() method in tableservice.py and the table doesn't exists, it will print a client request error and then return the False value.

How to reproduce

from azure.cosmosdb.table.tableservice import TableService
service = TableService(account_name="XXXXXX", account_key="XXXXXXXXX")

service.exists(table_name='Example')

If table Example doesn't exist, it will throw something like this in the console:

Client-Request-ID=7aca4ca3-581c-11eb-ab99-107b44503aa4 Retry policy did not allow for a retry: Server-Timestamp=Sat, 16 Jan 2021 17:01:31 GMT, Server-Request-ID=1e3a65d2-b002-0038-6729-ec7d93000000, HTTP status code=404, Exception=Not Found{"odata.error":{"code":"ResourceNotFound","message":{"lang":"en-US","value":"The specified resource does not exist.\nRequestId:1e3a65d2-b002-0038-6729-ec7d93000000\nTime:2021-01-16T17:01:31.9758209Z"}}}.

False

The expected output is just a False.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant