Skip to content

Commit 3fa0f84

Browse files
committed
Modify allowed proposals for trigger_xchem
1 parent 4e8ec90 commit 3fa0f84

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

src/dlstbx/services/trigger_xchem.py

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -236,18 +236,17 @@ def trigger_pandda_xchem(
236236

237237
query = (session.query(Proposal)).filter(Proposal.proposalId == proposal_id)
238238
proposal = query.first()
239+
proposal_code = proposal.proposalCode
240+
proposal_number = proposal.proposalNumber
241+
proposal_string = proposal_code + proposal_number
239242

240-
# 0. Check that this is an XChem expt & locate .SQLite database
241-
if proposal.proposalCode not in {"lb"}:
242-
self.log.debug(
243-
f"Not triggering PanDDA2 pipeline for dcid={dcid} with proposal_code={proposal.proposalCode}"
244-
)
245-
return {"success": True}
243+
# TEMPORARY FILTER
244+
allowed_proposals = ["lb42888", "sw44107"]
246245

247-
# TEMPORARY, FILTER BY OPENBIND VISIT
248-
if proposal.proposalNumber not in {"42888"}:
246+
# 0. Check that this is an XChem expt & locate .SQLite database
247+
if proposal_string not in allowed_proposals:
249248
self.log.debug(
250-
f"Not triggering PanDDA2 pipeline for dcid={dcid}, only accepting data collections from lb42888 during test phase"
249+
f"Not triggering PanDDA2 pipeline for dcid={dcid} proposal {proposal_string}"
251250
)
252251
return {"success": True}
253252

0 commit comments

Comments
 (0)