Skip to content

Commit

Permalink
Update main.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Don-Yin committed Nov 18, 2024
1 parent 1c3ed2a commit 94fa44e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions MetricDB/src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,10 @@


class MetricDB:
def __init__(self, base_dir: Path, name_datafile: str = "default.db", verbose: bool = True):
def __init__(self, datafile_dir: str = "default.db", verbose: bool = True):

# fmt: off
self.base_dir, self.verbose = Path(base_dir).mkdir(parents=True, exist_ok=True) or Path(base_dir), verbose
self.datafile_dir = self.base_dir / name_datafile
self.verbose, self.datafile_dir = verbose, Path(datafile_dir)
# fmt: on

self.connect = sqlite3.connect(self.datafile_dir)
Expand Down

0 comments on commit 94fa44e

Please sign in to comment.