You are trying to drop or alter a table when you get an error.
Error in SQL statement: IOException: Bucket_name … does not exist
You can reproduce the error with a
DROP TABLE or
ALTER TABLE command.
DROP TABLE <database-name.table-name>;
ALTER TABLE <database-name.table-name> SET LOCATION "<file-system-location>";
You deleted the contents of the underlying S3 bucket before dropping the tables.
Because the data no longer exists, you get an error when trying to drop the table.