Skip to content

Commit

Permalink
strip dataroot from TU GRAZ data and use temporary file for tmpuris
Browse files Browse the repository at this point in the history
  • Loading branch information
Roelof Rietbroek committed Jan 23, 2024
1 parent 730c062 commit 7d803b5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion geoslurp/dataset/dataSetBase.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ def retainnewUris(self,urilist):
#setup a seperate session and transaction in order to work with a temporary table
trans,ses=self.db.transsession()

tmptable=self.db.createTable('tmpuris',cols,temporary=False,bind=ses.get_bind())
tmptable=self.db.createTable('tmpuris',cols,temporary=True,bind=ses.get_bind())
# tmptable=self.db.createTable('tmpuris',cols,temporary=False,bind=ses.get_bind())
# import pdb;pdb.set_trace()
#fill the table with the file list and last modification timsstamps
Expand Down
4 changes: 3 additions & 1 deletion geoslurp_userplugins/TUGRAZDsets.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ class TUGRAZGRACEL2Base(DataSet):
scheme=scheme
release=''
subdirs=''
stripuri=True
def __init__(self,dbconn):
super().__init__(dbconn)
#initialize postgreslq table
Expand All @@ -130,7 +131,7 @@ def register(self):
files=self.updated
else:
files=[UriFile(file) for file in findFiles(self._dbinvent.datadir,'.*gfc.gz',since=self._dbinvent.lastupdate)]

# breakpoint()
newfiles=self.retainnewUris(files)
#loop over files
for uri in newfiles:
Expand All @@ -149,6 +150,7 @@ class TUGRAZGRACEL2NormalBase(DataSet):
release=''
subdirs=''
updated=False
stripuri=True
def __init__(self,dbconn):
super().__init__(dbconn)

Expand Down

0 comments on commit 7d803b5

Please sign in to comment.