This is an automated email from the ASF dual-hosted git repository. dill0wn pushed a commit to branch dw/pymongo4 in repository https://gitbox.apache.org/repos/asf/allura.git
commit 58badb930c316c8a1ea7799cb43509922fed7f80 Author: Dillon Walls <dillon.wa...@slashdotmedia.com> AuthorDate: Wed Jun 19 15:27:44 2024 -0400 replace deprecated ming/mongo database_names() with list_database_names() --- Allura/allura/websetup/bootstrap.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Allura/allura/websetup/bootstrap.py b/Allura/allura/websetup/bootstrap.py index 21cfa6781..981df8438 100644 --- a/Allura/allura/websetup/bootstrap.py +++ b/Allura/allura/websetup/bootstrap.py @@ -279,10 +279,10 @@ def wipe_database(): conn = M.main_doc_session.bind.conn if isinstance(conn, mim.Connection): clear_all_database_tables() - for db in conn.database_names(): + for db in conn.list_database_names(): db = conn[db] else: - for database in conn.database_names(): + for database in conn.list_database_names(): if database not in ('allura', 'pyforge', 'project-data'): continue log.info('Wiping database %s', database) @@ -299,7 +299,7 @@ def wipe_database(): def clear_all_database_tables(): conn = M.main_doc_session.bind.conn - for db in conn.database_names(): + for db in conn.list_database_names(): db = conn[db] for coll in list(db.collection_names()): if coll == 'system.indexes':