diff --git a/setup.py b/setup.py index b1de944..a04bede 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ setup( name='sysrev', - version='1.3.2', + version='1.3.3', description='get sysrev project data and use the sysrev api', long_description=long_description, long_description_content_type='text/markdown', # Specify the content type here diff --git a/sysrev/client.py b/sysrev/client.py index 22a5f40..145f5bd 100644 --- a/sysrev/client.py +++ b/sysrev/client.py @@ -93,7 +93,12 @@ def create_sqlite_db(): conn.commit() conn.close() + # TODO - this could be made more efficient by checking sqlite state and updating the sysrev api def sync(self, client, project_id): + # check that db exists + if not pathlib.Path('.sr/sr.sqlite').exists(): + self.create_sqlite_db() + project_info = client.get_project_info(project_id) labels = client.get_labels(project_id)