Skip to content

Commit

Permalink
Fix to dataset delete syntax (#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenOman authored Oct 29, 2024
1 parent c7fa128 commit 079fb3d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nle/dataset/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,8 @@ def create_dataset(dataset_name, root, ttyrec_version=0, conn=None, commit=True)

def delete_dataset(dataset_name, conn=None, commit=True):
with db(conn, rw=True) as conn:
conn.execute("DELETE datasets WHERE dataset_name=?", (dataset_name,))
conn.execute("DELETE roots WHERE dataset_name=?", (dataset_name,))
conn.execute("DELETE FROM datasets WHERE dataset_name=?", (dataset_name,))
conn.execute("DELETE FROM roots WHERE dataset_name=?", (dataset_name,))
conn.execute("UPDATE meta SET mtime = ?", (time.time(),))
if commit:
conn.commit()
Expand Down

0 comments on commit 079fb3d

Please sign in to comment.