Skip to content

Commit ab8997e

Browse files
Release/1.5.0 (#53)
* Feature/checksum maintenance (#50) This PR introduces a maintenance task that will refresh the path info db and update missing checksums * Feature/checksum maintenance (#52) This PR favors the ChecksumCalculationTask over the path info db refresh task and has been confirmed to work in a openbis 18.06.2 test instance. * Update CL * Add new line at end of file Add new line at end of file * convert experiment id to string for v3 objects * Convert experiment id to string for v3 objects (#55) * Rename data folder for pooled data (#54) * adapt changelog Co-authored-by: wow-such-code <[email protected]>
1 parent 468887b commit ab8997e

File tree

4 files changed

+15
-25
lines changed

4 files changed

+15
-25
lines changed

CHANGELOG.md

+7
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
# Changelog
22

3+
4+
## 1.5.0 2020-11-03
5+
6+
* New maintenance task: update missing checksum once, after dss starts.
7+
* Fix for nanopore registration: rename folders for pooling case
8+
* Fix for experiment update: force identifier into a string to support v3 API objects
9+
310
## 1.4.1 2020-11-03
411

512
* Imgag dropbox: raise an exception, if files of unknown type are part of the transaction

drop-boxes/register-nanopore-dropbox/register-nanopore.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -226,12 +226,15 @@ def registerUnclassifiedData(transaction, unclassifiedDataMap, runExperiment, cu
226226
# moves a subset of nanopore data to a new target path, needed to add fastq and fast5 subfolders to the same dataset
227227
def prepareDataFolder(incomingPath, currentPath, destinationPath, dataObject, suffix):
228228
name = dataObject.getName()
229+
# if pooled data, folder is named using barcode and needs to be adapted
230+
if not "_" in name:
231+
name = name + "_" + suffix
229232
relativePath = dataObject.getRelativePath()
230233
# the source path of the currently handled data object (e.g. fast5_fail folder)
231234
sourcePath = os.path.join(os.path.dirname(currentPath), relativePath)
232235
checksumFile = createChecksumFileForFolder(incomingPath, sourcePath)
233236
# destination path containing data type (fastq or fast5), as well as the parent sample code, so pooled samples can be handled
234-
destination = os.path.join(destinationPath, name + "_" + suffix)
237+
destination = os.path.join(destinationPath, name)
235238
os.rename(sourcePath, destination)
236239

237240
def createSampleWithData(transaction, space, parentSampleCode, mapWithDataForSample, openbisExperiment, currentPath, absLogPath):
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Updates missing checksums
2+
class = ch.systemsx.cisd.etlserver.path.PathInfoDatabaseChecksumCalculationTask
3+
execute-only-once = true
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
import smtplib
2-
from email.mime.text import MIMEText
31

42
def process(tr, parameters, tableBuilder):
53
"""Change properties of experiment
@@ -9,30 +7,9 @@ def process(tr, parameters, tableBuilder):
97
if not user == None:
108
tr.setUserId(user)
119
expId = parameters.get("identifier")
12-
exp = tr.getExperimentForUpdate(expId)
10+
exp = tr.getExperimentForUpdate(str(expId))
1311

1412
properties = parameters.get("properties")
1513

1614
for prop in properties.keySet():
1715
exp.setPropertyValue(prop, properties.get(prop))
18-
19-
#server = "smtpserv.uni-tuebingen.de"
20-
#fromA = "[email protected]"
21-
22-
# TODO get emails of space users
23-
# Get it via liferay and pass it to this service ?
24-
25-
#subject = "Update information for Experiment %s" % expId
26-
#text = "Status of Experiment %s has been updated" % expId #, properties.get("Q_CURRENT_STATUS"))
27-
28-
#msg = MIMEText(text)
29-
#msg['From'] = fromA
30-
#msg['To'] = toA
31-
#msg['Subject'] = subject
32-
# check for [email protected]
33-
#msg['reply-to'] = "[email protected]"
34-
35-
#smtpServer = smtplib.SMTP(server)
36-
#smtpServer.sendmail(fromA, toA, msg.as_string())
37-
#smtpServer.close()
38-

0 commit comments

Comments
 (0)