MCPcopy Index your code
hub / github.com/tortoise/tortoise-orm / db_delete

Method db_delete

tortoise/backends/mysql/client.py:173–179  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

171 await self.close()
172
173 async def db_delete(self) -> None:
174 await self.create_connection(with_db=False)
175 try:
176 await self.execute_script(f"DROP DATABASE {self.database}")
177 except errors.DatabaseError: # pragma: nocoverage
178 pass
179 await self.close()
180
181 def acquire_connection(self) -> ConnectionWrapper | PoolConnectionWrapper:
182 return PoolConnectionWrapper(self, self._pool_init_lock)

Callers

nothing calls this directly

Calls 3

create_connectionMethod · 0.95
execute_scriptMethod · 0.95
closeMethod · 0.95

Tested by

no test coverage detected