I'm deleting a site using code like this:
tableau_auth = TSC.TableauAuth(args.username, password, site=args.contentUrl)
with server.auth.sign_in(tableau_auth):
server.sites.delete(site_id)
print("\nSite deleted.")
Note that in order to delete a site, I have to sign into that site by including the contentUrl. (The site_id value was fetched earlier in the program from which I take this snippet.) This code works--the site is deleted.
However, at the termination of the with block, the code implicitly attempts to sign out from the site. But the site doesn't exist any more, so the signout fails and throws all sorts of errors.
I'm deleting a site using code like this:
Note that in order to delete a site, I have to sign into that site by including the contentUrl. (The site_id value was fetched earlier in the program from which I take this snippet.) This code works--the site is deleted.
However, at the termination of the with block, the code implicitly attempts to sign out from the site. But the site doesn't exist any more, so the signout fails and throws all sorts of errors.